
// this is autogenerated file, do not edit it.
#include "ficus/ficus.h"

struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t;

static void _fx_free_Nt10Hashset__t1R9Ast__id_t(struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t** dst);

struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t;

static void _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t** dst);

struct _fx_N13Ast__binary_t_data_t;

static void _fx_free_N13Ast__binary_t(struct _fx_N13Ast__binary_t_data_t** dst);

struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t;

static void _fx_free_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t** dst);

struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t;

static void _fx_free_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t** dst);

struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t;

static void _fx_free_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t** dst);

struct _fx_N14K_form__ktyp_t_data_t;

static void _fx_free_N14K_form__ktyp_t(struct _fx_N14K_form__ktyp_t_data_t** dst);

struct _fx_N14K_form__kexp_t_data_t;

static void _fx_free_N14K_form__kexp_t(struct _fx_N14K_form__kexp_t_data_t** dst);

struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t;

static void _fx_free_Nt10Hashmap__t2R9Ast__id_ti(struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t** dst);

struct _fx_N14C_form__ctyp_t_data_t;

static void _fx_free_N14C_form__ctyp_t(struct _fx_N14C_form__ctyp_t_data_t** dst);

struct _fx_N14C_form__cexp_t_data_t;

static void _fx_free_N14C_form__cexp_t(struct _fx_N14C_form__cexp_t_data_t** dst);

struct _fx_N15C_form__cstmt_t_data_t;

static void _fx_free_N15C_form__cstmt_t(struct _fx_N15C_form__cstmt_t_data_t** dst);

struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t;

static void _fx_free_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t** dst);

typedef struct _fx_LS_data_t {
   int_ rc;
   struct _fx_LS_data_t* tl;
   fx_str_t hd;
} _fx_LS_data_t, *_fx_LS;

typedef struct _fx_Ta2i {
   int_ t0;
   int_ t1;
} _fx_Ta2i;

typedef struct _fx_T2Ta2iS {
   struct _fx_Ta2i t0;
   fx_str_t t1;
} _fx_T2Ta2iS;

typedef struct _fx_R9Ast__id_t {
   int_ m;
   int_ i;
   int_ j;
} _fx_R9Ast__id_t;

typedef struct _fx_R10Ast__loc_t {
   int_ m_idx;
   int_ line0;
   int_ col0;
   int_ line1;
   int_ col1;
} _fx_R10Ast__loc_t;

typedef struct _fx_T2R9Ast__id_ti {
   struct _fx_R9Ast__id_t t0;
   int_ t1;
} _fx_T2R9Ast__id_ti;

typedef struct _fx_T2Bi {
   bool t0;
   int_ t1;
} _fx_T2Bi;

typedef struct _fx_N12Ast__scope_t {
   int tag;
   union {
      int_ ScBlock;
      struct _fx_T2Bi ScLoop;
      int_ ScFold;
      int_ ScArrMap;
      int_ ScMap;
      int_ ScTry;
      struct _fx_R9Ast__id_t ScFun;
      struct _fx_R9Ast__id_t ScClass;
      struct _fx_R9Ast__id_t ScInterface;
      int_ ScModule;
   } u;
} _fx_N12Ast__scope_t;

typedef struct _fx_LN12Ast__scope_t_data_t {
   int_ rc;
   struct _fx_LN12Ast__scope_t_data_t* tl;
   struct _fx_N12Ast__scope_t hd;
} _fx_LN12Ast__scope_t_data_t, *_fx_LN12Ast__scope_t;

typedef struct _fx_R16Ast__val_flags_t {
   bool val_flag_arg;
   bool val_flag_mutable;
   bool val_flag_temp;
   bool val_flag_tempref;
   bool val_flag_private;
   bool val_flag_subarray;
   bool val_flag_instance;
   struct _fx_T2R9Ast__id_ti val_flag_method;
   int_ val_flag_ctor;
   struct _fx_LN12Ast__scope_t_data_t* val_flag_global;
} _fx_R16Ast__val_flags_t;

typedef struct _fx_R17C_form__cdefval_t {
   struct _fx_R9Ast__id_t cv_name;
   struct _fx_N14C_form__ctyp_t_data_t* cv_typ;
   fx_str_t cv_cname;
   struct _fx_R16Ast__val_flags_t cv_flags;
   struct _fx_R10Ast__loc_t cv_loc;
} _fx_R17C_form__cdefval_t;

typedef struct _fx_R19C_form__cdeflabel_t {
   struct _fx_R9Ast__id_t cl_name;
   fx_str_t cl_cname;
   struct _fx_R10Ast__loc_t cl_loc;
} _fx_R19C_form__cdeflabel_t;

typedef struct _fx_T2R9Ast__id_tN14C_form__ctyp_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
} _fx_T2R9Ast__id_tN14C_form__ctyp_t;

typedef struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t {
   int_ rc;
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* tl;
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t hd;
} _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t, *_fx_LT2R9Ast__id_tN14C_form__ctyp_t;

typedef struct _fx_R23C_form__cdefinterface_t {
   struct _fx_R9Ast__id_t ci_name;
   fx_str_t ci_cname;
   struct _fx_R9Ast__id_t ci_id;
   struct _fx_R9Ast__id_t ci_vtbl;
   struct _fx_R9Ast__id_t ci_base;
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* ci_all_methods;
   struct _fx_LN12Ast__scope_t_data_t* ci_scope;
   struct _fx_R10Ast__loc_t ci_loc;
} _fx_R23C_form__cdefinterface_t;

typedef struct _fx_rR23C_form__cdefinterface_t_data_t {
   int_ rc;
   struct _fx_R23C_form__cdefinterface_t data;
} _fx_rR23C_form__cdefinterface_t_data_t, *_fx_rR23C_form__cdefinterface_t;

typedef struct _fx_N17Ast__fun_constr_t {
   int tag;
   union {
      int_ CtorVariant;
      struct _fx_R9Ast__id_t CtorFP;
      struct _fx_R9Ast__id_t CtorExn;
   } u;
} _fx_N17Ast__fun_constr_t;

typedef struct _fx_R16Ast__fun_flags_t {
   int_ fun_flag_pure;
   bool fun_flag_ccode;
   bool fun_flag_have_keywords;
   bool fun_flag_inline;
   bool fun_flag_nothrow;
   bool fun_flag_really_nothrow;
   bool fun_flag_private;
   struct _fx_N17Ast__fun_constr_t fun_flag_ctor;
   struct _fx_R9Ast__id_t fun_flag_method_of;
   bool fun_flag_uses_fv;
   bool fun_flag_recursive;
   bool fun_flag_instance;
} _fx_R16Ast__fun_flags_t;

typedef struct _fx_LN15C_form__cstmt_t_data_t {
   int_ rc;
   struct _fx_LN15C_form__cstmt_t_data_t* tl;
   struct _fx_N15C_form__cstmt_t_data_t* hd;
} _fx_LN15C_form__cstmt_t_data_t, *_fx_LN15C_form__cstmt_t;

typedef struct _fx_N19C_form__carg_attr_t {
   int tag;
} _fx_N19C_form__carg_attr_t;

typedef struct _fx_LN19C_form__carg_attr_t_data_t {
   int_ rc;
   struct _fx_LN19C_form__carg_attr_t_data_t* tl;
   struct _fx_N19C_form__carg_attr_t hd;
} _fx_LN19C_form__carg_attr_t_data_t, *_fx_LN19C_form__carg_attr_t;

typedef struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
   struct _fx_LN19C_form__carg_attr_t_data_t* t2;
} _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t;

typedef struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t {
   int_ rc;
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* tl;
   struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t hd;
} _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t, *_fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t;

typedef struct _fx_R17C_form__cdeffun_t {
   struct _fx_R9Ast__id_t cf_name;
   fx_str_t cf_cname;
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* cf_args;
   struct _fx_N14C_form__ctyp_t_data_t* cf_rt;
   struct _fx_LN15C_form__cstmt_t_data_t* cf_body;
   struct _fx_R16Ast__fun_flags_t cf_flags;
   struct _fx_LN12Ast__scope_t_data_t* cf_scope;
   struct _fx_R10Ast__loc_t cf_loc;
} _fx_R17C_form__cdeffun_t;

typedef struct _fx_rR17C_form__cdeffun_t_data_t {
   int_ rc;
   struct _fx_R17C_form__cdeffun_t data;
} _fx_rR17C_form__cdeffun_t_data_t, *_fx_rR17C_form__cdeffun_t;

typedef struct _fx_Ta2R9Ast__id_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_R9Ast__id_t t1;
} _fx_Ta2R9Ast__id_t;

typedef struct _fx_LR9Ast__id_t_data_t {
   int_ rc;
   struct _fx_LR9Ast__id_t_data_t* tl;
   struct _fx_R9Ast__id_t hd;
} _fx_LR9Ast__id_t_data_t, *_fx_LR9Ast__id_t;

typedef struct _fx_R17C_form__ctprops_t {
   bool ctp_scalar;
   bool ctp_complex;
   bool ctp_ptr;
   bool ctp_pass_by_ref;
   struct _fx_LR9Ast__id_t_data_t* ctp_make;
   struct _fx_Ta2R9Ast__id_t ctp_free;
   struct _fx_Ta2R9Ast__id_t ctp_copy;
} _fx_R17C_form__ctprops_t;

typedef struct _fx_R17C_form__cdeftyp_t {
   struct _fx_R9Ast__id_t ct_name;
   struct _fx_N14C_form__ctyp_t_data_t* ct_typ;
   fx_str_t ct_cname;
   struct _fx_R17C_form__ctprops_t ct_props;
   int_ ct_data_start;
   struct _fx_R9Ast__id_t ct_enum;
   struct _fx_LR9Ast__id_t_data_t* ct_ifaces;
   struct _fx_R9Ast__id_t ct_ifaces_id;
   struct _fx_LN12Ast__scope_t_data_t* ct_scope;
   struct _fx_R10Ast__loc_t ct_loc;
} _fx_R17C_form__cdeftyp_t;

typedef struct _fx_rR17C_form__cdeftyp_t_data_t {
   int_ rc;
   struct _fx_R17C_form__cdeftyp_t data;
} _fx_rR17C_form__cdeftyp_t_data_t, *_fx_rR17C_form__cdeftyp_t;

typedef struct _fx_Nt6option1N14C_form__cexp_t {
   int tag;
   union {
      struct _fx_N14C_form__cexp_t_data_t* Some;
   } u;
} _fx_Nt6option1N14C_form__cexp_t;

typedef struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_Nt6option1N14C_form__cexp_t t1;
} _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t;

typedef struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t* tl;
   struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t hd;
} _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t, *_fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t;

typedef struct _fx_R18C_form__cdefenum_t {
   struct _fx_R9Ast__id_t cenum_name;
   struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t* cenum_members;
   fx_str_t cenum_cname;
   struct _fx_LN12Ast__scope_t_data_t* cenum_scope;
   struct _fx_R10Ast__loc_t cenum_loc;
} _fx_R18C_form__cdefenum_t;

typedef struct _fx_rR18C_form__cdefenum_t_data_t {
   int_ rc;
   struct _fx_R18C_form__cdefenum_t data;
} _fx_rR18C_form__cdefenum_t_data_t, *_fx_rR18C_form__cdefenum_t;

typedef struct _fx_R19C_form__cdefmacro_t {
   struct _fx_R9Ast__id_t cm_name;
   fx_str_t cm_cname;
   struct _fx_LR9Ast__id_t_data_t* cm_args;
   struct _fx_LN15C_form__cstmt_t_data_t* cm_body;
   struct _fx_LN12Ast__scope_t_data_t* cm_scope;
   struct _fx_R10Ast__loc_t cm_loc;
} _fx_R19C_form__cdefmacro_t;

typedef struct _fx_rR19C_form__cdefmacro_t_data_t {
   int_ rc;
   struct _fx_R19C_form__cdefmacro_t data;
} _fx_rR19C_form__cdefmacro_t_data_t, *_fx_rR19C_form__cdefmacro_t;

typedef struct _fx_R17C_form__cdefexn_t {
   struct _fx_R9Ast__id_t cexn_name;
   fx_str_t cexn_cname;
   fx_str_t cexn_base_cname;
   struct _fx_N14C_form__ctyp_t_data_t* cexn_typ;
   bool cexn_std;
   struct _fx_R9Ast__id_t cexn_tag;
   struct _fx_R9Ast__id_t cexn_data;
   struct _fx_R9Ast__id_t cexn_info;
   struct _fx_R9Ast__id_t cexn_make;
   struct _fx_LN12Ast__scope_t_data_t* cexn_scope;
   struct _fx_R10Ast__loc_t cexn_loc;
} _fx_R17C_form__cdefexn_t;

typedef struct _fx_rR17C_form__cdefexn_t_data_t {
   int_ rc;
   struct _fx_R17C_form__cdefexn_t data;
} _fx_rR17C_form__cdefexn_t_data_t, *_fx_rR17C_form__cdefexn_t;

typedef struct _fx_N15C_form__cinfo_t {
   int tag;
   union {
      struct _fx_R17C_form__cdefval_t CVal;
      struct _fx_rR17C_form__cdeffun_t_data_t* CFun;
      struct _fx_rR17C_form__cdeftyp_t_data_t* CTyp;
      struct _fx_rR17C_form__cdefexn_t_data_t* CExn;
      struct _fx_rR23C_form__cdefinterface_t_data_t* CInterface;
      struct _fx_rR18C_form__cdefenum_t_data_t* CEnum;
      struct _fx_R19C_form__cdeflabel_t CLabel;
      struct _fx_rR19C_form__cdefmacro_t_data_t* CMacro;
   } u;
} _fx_N15C_form__cinfo_t;

typedef struct _fx_R17K_form__kdefval_t {
   struct _fx_R9Ast__id_t kv_name;
   fx_str_t kv_cname;
   struct _fx_N14K_form__ktyp_t_data_t* kv_typ;
   struct _fx_R16Ast__val_flags_t kv_flags;
   struct _fx_R10Ast__loc_t kv_loc;
} _fx_R17K_form__kdefval_t;

typedef struct _fx_T2R9Ast__id_tN14K_form__ktyp_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14K_form__ktyp_t_data_t* t1;
} _fx_T2R9Ast__id_tN14K_form__ktyp_t;

typedef struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t {
   int_ rc;
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* tl;
   struct _fx_T2R9Ast__id_tN14K_form__ktyp_t hd;
} _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t, *_fx_LT2R9Ast__id_tN14K_form__ktyp_t;

typedef struct _fx_R23K_form__kdefinterface_t {
   struct _fx_R9Ast__id_t ki_name;
   struct _fx_R9Ast__id_t ki_base;
   fx_str_t ki_cname;
   struct _fx_R9Ast__id_t ki_id;
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* ki_all_methods;
   struct _fx_LN12Ast__scope_t_data_t* ki_scope;
   struct _fx_R10Ast__loc_t ki_loc;
} _fx_R23K_form__kdefinterface_t;

typedef struct _fx_rR23K_form__kdefinterface_t_data_t {
   int_ rc;
   struct _fx_R23K_form__kdefinterface_t data;
} _fx_rR23K_form__kdefinterface_t_data_t, *_fx_rR23K_form__kdefinterface_t;

typedef struct _fx_R25K_form__kdefclosureinfo_t {
   struct _fx_R9Ast__id_t kci_arg;
   struct _fx_R9Ast__id_t kci_fcv_t;
   struct _fx_R9Ast__id_t kci_fp_typ;
   struct _fx_R9Ast__id_t kci_make_fp;
   struct _fx_R9Ast__id_t kci_wrap_f;
} _fx_R25K_form__kdefclosureinfo_t;

typedef struct _fx_R17K_form__kdeffun_t {
   struct _fx_R9Ast__id_t kf_name;
   fx_str_t kf_cname;
   struct _fx_LR9Ast__id_t_data_t* kf_params;
   struct _fx_N14K_form__ktyp_t_data_t* kf_rt;
   struct _fx_N14K_form__kexp_t_data_t* kf_body;
   struct _fx_R16Ast__fun_flags_t kf_flags;
   struct _fx_R25K_form__kdefclosureinfo_t kf_closure;
   struct _fx_LN12Ast__scope_t_data_t* kf_scope;
   struct _fx_R10Ast__loc_t kf_loc;
} _fx_R17K_form__kdeffun_t;

typedef struct _fx_rR17K_form__kdeffun_t_data_t {
   int_ rc;
   struct _fx_R17K_form__kdeffun_t data;
} _fx_rR17K_form__kdeffun_t_data_t, *_fx_rR17K_form__kdeffun_t;

typedef struct _fx_R17K_form__kdefexn_t {
   struct _fx_R9Ast__id_t ke_name;
   fx_str_t ke_cname;
   fx_str_t ke_base_cname;
   struct _fx_N14K_form__ktyp_t_data_t* ke_typ;
   bool ke_std;
   struct _fx_R9Ast__id_t ke_tag;
   struct _fx_R9Ast__id_t ke_make;
   struct _fx_LN12Ast__scope_t_data_t* ke_scope;
   struct _fx_R10Ast__loc_t ke_loc;
} _fx_R17K_form__kdefexn_t;

typedef struct _fx_rR17K_form__kdefexn_t_data_t {
   int_ rc;
   struct _fx_R17K_form__kdefexn_t data;
} _fx_rR17K_form__kdefexn_t_data_t, *_fx_rR17K_form__kdefexn_t;

typedef struct _fx_R17K_form__ktprops_t {
   bool ktp_complex;
   bool ktp_scalar;
   bool ktp_ptr;
   bool ktp_pass_by_ref;
   bool ktp_custom_free;
   bool ktp_custom_copy;
} _fx_R17K_form__ktprops_t;

typedef struct _fx_Nt6option1R17K_form__ktprops_t {
   int tag;
   union {
      struct _fx_R17K_form__ktprops_t Some;
   } u;
} _fx_Nt6option1R17K_form__ktprops_t;

typedef struct _fx_R16Ast__var_flags_t {
   int_ var_flag_class_from;
   bool var_flag_record;
   bool var_flag_recursive;
   bool var_flag_have_tag;
   bool var_flag_have_mutable;
   bool var_flag_opt;
   bool var_flag_instance;
} _fx_R16Ast__var_flags_t;

typedef struct _fx_LN14K_form__ktyp_t_data_t {
   int_ rc;
   struct _fx_LN14K_form__ktyp_t_data_t* tl;
   struct _fx_N14K_form__ktyp_t_data_t* hd;
} _fx_LN14K_form__ktyp_t_data_t, *_fx_LN14K_form__ktyp_t;

typedef struct _fx_T2R9Ast__id_tLR9Ast__id_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_LR9Ast__id_t_data_t* t1;
} _fx_T2R9Ast__id_tLR9Ast__id_t;

typedef struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t {
   int_ rc;
   struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t* tl;
   struct _fx_T2R9Ast__id_tLR9Ast__id_t hd;
} _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t, *_fx_LT2R9Ast__id_tLR9Ast__id_t;

typedef struct _fx_R21K_form__kdefvariant_t {
   struct _fx_R9Ast__id_t kvar_name;
   fx_str_t kvar_cname;
   struct _fx_R9Ast__id_t kvar_proto;
   struct _fx_Nt6option1R17K_form__ktprops_t kvar_props;
   struct _fx_LN14K_form__ktyp_t_data_t* kvar_targs;
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* kvar_cases;
   struct _fx_LR9Ast__id_t_data_t* kvar_ctors;
   struct _fx_R16Ast__var_flags_t kvar_flags;
   struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t* kvar_ifaces;
   struct _fx_LN12Ast__scope_t_data_t* kvar_scope;
   struct _fx_R10Ast__loc_t kvar_loc;
} _fx_R21K_form__kdefvariant_t;

typedef struct _fx_rR21K_form__kdefvariant_t_data_t {
   int_ rc;
   struct _fx_R21K_form__kdefvariant_t data;
} _fx_rR21K_form__kdefvariant_t_data_t, *_fx_rR21K_form__kdefvariant_t;

typedef struct _fx_R17K_form__kdeftyp_t {
   struct _fx_R9Ast__id_t kt_name;
   fx_str_t kt_cname;
   struct _fx_R9Ast__id_t kt_proto;
   struct _fx_Nt6option1R17K_form__ktprops_t kt_props;
   struct _fx_LN14K_form__ktyp_t_data_t* kt_targs;
   struct _fx_N14K_form__ktyp_t_data_t* kt_typ;
   struct _fx_LN12Ast__scope_t_data_t* kt_scope;
   struct _fx_R10Ast__loc_t kt_loc;
} _fx_R17K_form__kdeftyp_t;

typedef struct _fx_rR17K_form__kdeftyp_t_data_t {
   int_ rc;
   struct _fx_R17K_form__kdeftyp_t data;
} _fx_rR17K_form__kdeftyp_t_data_t, *_fx_rR17K_form__kdeftyp_t;

typedef struct _fx_R25K_form__kdefclosurevars_t {
   struct _fx_R9Ast__id_t kcv_name;
   fx_str_t kcv_cname;
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* kcv_freevars;
   struct _fx_LR9Ast__id_t_data_t* kcv_orig_freevars;
   struct _fx_LN12Ast__scope_t_data_t* kcv_scope;
   struct _fx_R10Ast__loc_t kcv_loc;
} _fx_R25K_form__kdefclosurevars_t;

typedef struct _fx_rR25K_form__kdefclosurevars_t_data_t {
   int_ rc;
   struct _fx_R25K_form__kdefclosurevars_t data;
} _fx_rR25K_form__kdefclosurevars_t_data_t, *_fx_rR25K_form__kdefclosurevars_t;

typedef struct _fx_N15K_form__kinfo_t {
   int tag;
   union {
      struct _fx_R17K_form__kdefval_t KVal;
      struct _fx_rR17K_form__kdeffun_t_data_t* KFun;
      struct _fx_rR17K_form__kdefexn_t_data_t* KExn;
      struct _fx_rR21K_form__kdefvariant_t_data_t* KVariant;
      struct _fx_rR25K_form__kdefclosurevars_t_data_t* KClosureVars;
      struct _fx_rR23K_form__kdefinterface_t_data_t* KInterface;
      struct _fx_rR17K_form__kdeftyp_t_data_t* KTyp;
   } u;
} _fx_N15K_form__kinfo_t;

typedef struct _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t {
   uint64_t hv;
   struct _fx_R9Ast__id_t key;
} _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t;

typedef struct _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t {
   struct _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t t0;
   int_ t1;
   int_ t2;
   int_ t3;
   fx_arr_t t4;
   fx_arr_t t5;
} _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t;

typedef struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t {
   int_ rc;
   union {
      struct _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t t;
   } u;
} _fx_Nt10Hashset__t1R9Ast__id_t_data_t, *_fx_Nt10Hashset__t1R9Ast__id_t;

typedef struct _fx_FPi2R9Ast__id_tR9Ast__id_t {
   int (*fp)(struct _fx_R9Ast__id_t*, struct _fx_R9Ast__id_t*, int_*, void*);
   fx_fcv_t* fcv;
} _fx_FPi2R9Ast__id_tR9Ast__id_t;

typedef struct _fx_N12Map__color_t {
   int tag;
} _fx_N12Map__color_t;

typedef struct _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t {
   struct _fx_N12Map__color_t t0;
   struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t* t1;
   struct _fx_R9Ast__id_t t2;
   struct _fx_R9Ast__id_t t3;
   struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t* t4;
} _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t;

typedef struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t {
   int_ rc;
   union {
      struct _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t
         Node;
   } u;
} _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t, *_fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t;

typedef struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t {
   struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t* root;
   struct _fx_FPi2R9Ast__id_tR9Ast__id_t cmp;
} _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t;

typedef struct _fx_T2R10Ast__loc_tS {
   struct _fx_R10Ast__loc_t t0;
   fx_str_t t1;
} _fx_T2R10Ast__loc_tS;

typedef struct _fx_N12Ast__cmpop_t {
   int tag;
} _fx_N12Ast__cmpop_t;

typedef struct _fx_N13Ast__binary_t_data_t {
   int_ rc;
   int tag;
   union {
      struct _fx_N12Ast__cmpop_t OpCmp;
      struct _fx_N12Ast__cmpop_t OpDotCmp;
      struct _fx_N13Ast__binary_t_data_t* OpAugBinary;
   } u;
} _fx_N13Ast__binary_t_data_t, *_fx_N13Ast__binary_t;

typedef struct _fx_N12Ast__unary_t {
   int tag;
} _fx_N12Ast__unary_t;

typedef struct _fx_N12Ast__sctyp_t {
   int tag;
} _fx_N12Ast__sctyp_t;

typedef struct _fx_N13Ast__intrin_t {
   int tag;
   union {
      struct _fx_R9Ast__id_t IntrinMath;
      struct _fx_N12Ast__sctyp_t IntrinSaturate;
   } u;
} _fx_N13Ast__intrin_t;

typedef struct _fx_N15Ast__for_make_t {
   int tag;
} _fx_N15Ast__for_make_t;

typedef struct _fx_R16Ast__for_flags_t {
   bool for_flag_parallel;
   struct _fx_N15Ast__for_make_t for_flag_make;
   bool for_flag_unzip;
   bool for_flag_fold;
   bool for_flag_nested;
} _fx_R16Ast__for_flags_t;

typedef struct _fx_T2SR10Ast__loc_t {
   fx_str_t t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2SR10Ast__loc_t;

typedef struct _fx_LT2SR10Ast__loc_t_data_t {
   int_ rc;
   struct _fx_LT2SR10Ast__loc_t_data_t* tl;
   struct _fx_T2SR10Ast__loc_t hd;
} _fx_LT2SR10Ast__loc_t_data_t, *_fx_LT2SR10Ast__loc_t;

typedef struct _fx_Li_data_t {
   int_ rc;
   struct _fx_Li_data_t* tl;
   int_ hd;
} _fx_Li_data_t, *_fx_Li;

typedef struct _fx_rB_data_t {
   int_ rc;
   bool data;
} _fx_rB_data_t, *_fx_rB;

typedef struct _fx_ri_data_t {
   int_ rc;
   int_ data;
} _fx_ri_data_t, *_fx_ri;

typedef struct _fx_T2il {
   int_ t0;
   int64_t t1;
} _fx_T2il;

typedef struct _fx_T2iq {
   int_ t0;
   uint64_t t1;
} _fx_T2iq;

typedef struct _fx_T2id {
   int_ t0;
   double t1;
} _fx_T2id;

typedef struct _fx_N14K_form__klit_t {
   int tag;
   union {
      int64_t KLitInt;
      struct _fx_T2il KLitSInt;
      struct _fx_T2iq KLitUInt;
      struct _fx_T2id KLitFloat;
      fx_str_t KLitString;
      char_ KLitChar;
      bool KLitBool;
      struct _fx_N14K_form__ktyp_t_data_t* KLitNil;
   } u;
} _fx_N14K_form__klit_t;

typedef struct _fx_N14K_form__atom_t {
   int tag;
   union {
      struct _fx_R9Ast__id_t AtomId;
      struct _fx_N14K_form__klit_t AtomLit;
   } u;
} _fx_N14K_form__atom_t;

typedef struct _fx_R22K_form__k_fold_callb_t {
   struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t* kcb_fold_ktyp;
   struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t* kcb_fold_kexp;
   struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t* kcb_fold_atom;
} _fx_R22K_form__k_fold_callb_t;

typedef struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t {
   int (*fp)(struct _fx_N14K_form__atom_t*, struct _fx_R10Ast__loc_t*, struct _fx_R22K_form__k_fold_callb_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t;

typedef struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t {
   int_ rc;
   union {
      struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t Some;
   } u;
} _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t, *_fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t;

typedef struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t {
   int (*fp)(struct _fx_N14K_form__kexp_t_data_t*, struct _fx_R22K_form__k_fold_callb_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t;

typedef struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t {
   int_ rc;
   union {
      struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t Some;
   } u;
} _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t, *_fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t;

typedef struct _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t {
   int (*fp)(struct _fx_N14K_form__ktyp_t_data_t*, struct _fx_R10Ast__loc_t*, struct _fx_R22K_form__k_fold_callb_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t;

typedef struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t {
   int_ rc;
   union {
      struct _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t Some;
   } u;
} _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t, *_fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t;

typedef struct _fx_Nt6option1N14K_form__atom_t {
   int tag;
   union {
      struct _fx_N14K_form__atom_t Some;
   } u;
} _fx_Nt6option1N14K_form__atom_t;

typedef struct _fx_LN14K_form__kexp_t_data_t {
   int_ rc;
   struct _fx_LN14K_form__kexp_t_data_t* tl;
   struct _fx_N14K_form__kexp_t_data_t* hd;
} _fx_LN14K_form__kexp_t_data_t, *_fx_LN14K_form__kexp_t;

typedef struct _fx_T2BN14K_form__atom_t {
   bool t0;
   struct _fx_N14K_form__atom_t t1;
} _fx_T2BN14K_form__atom_t;

typedef struct _fx_LT2BN14K_form__atom_t_data_t {
   int_ rc;
   struct _fx_LT2BN14K_form__atom_t_data_t* tl;
   struct _fx_T2BN14K_form__atom_t hd;
} _fx_LT2BN14K_form__atom_t_data_t, *_fx_LT2BN14K_form__atom_t;

typedef struct _fx_N13Ast__border_t {
   int tag;
} _fx_N13Ast__border_t;

typedef struct _fx_N18Ast__interpolate_t {
   int tag;
} _fx_N18Ast__interpolate_t;

typedef struct _fx_R14Ast__pragmas_t {
   bool pragma_cpp;
   struct _fx_LT2SR10Ast__loc_t_data_t* pragma_clibs;
} _fx_R14Ast__pragmas_t;

typedef struct _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t {
   struct _fx_LN14K_form__ktyp_t_data_t* t0;
   struct _fx_N14K_form__ktyp_t_data_t* t1;
} _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t;

typedef struct _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* t1;
} _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t;

typedef struct _fx_T2iN14K_form__ktyp_t {
   int_ t0;
   struct _fx_N14K_form__ktyp_t_data_t* t1;
} _fx_T2iN14K_form__ktyp_t;

typedef struct _fx_N14K_form__ktyp_t_data_t {
   int_ rc;
   int tag;
   union {
      int_ KTypSInt;
      int_ KTypUInt;
      int_ KTypFloat;
      struct _fx_N14K_form__ktyp_t_data_t* KTypRawPointer;
      struct _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t KTypFun;
      struct _fx_LN14K_form__ktyp_t_data_t* KTypTuple;
      struct _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t KTypRecord;
      struct _fx_R9Ast__id_t KTypName;
      struct _fx_T2iN14K_form__ktyp_t KTypArray;
      struct _fx_N14K_form__ktyp_t_data_t* KTypVector;
      struct _fx_N14K_form__ktyp_t_data_t* KTypList;
      struct _fx_N14K_form__ktyp_t_data_t* KTypRef;
   } u;
} _fx_N14K_form__ktyp_t_data_t, *_fx_N14K_form__ktyp_t;

typedef struct _fx_Ta3N14K_form__atom_t {
   struct _fx_N14K_form__atom_t t0;
   struct _fx_N14K_form__atom_t t1;
   struct _fx_N14K_form__atom_t t2;
} _fx_Ta3N14K_form__atom_t;

typedef struct _fx_N13K_form__dom_t {
   int tag;
   union {
      struct _fx_N14K_form__atom_t DomainElem;
      struct _fx_N14K_form__atom_t DomainFast;
      struct _fx_Ta3N14K_form__atom_t DomainRange;
   } u;
} _fx_N13K_form__dom_t;

typedef struct _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t {
   struct _fx_Nt6option1N14K_form__atom_t t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t;

typedef struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N14K_form__ktyp_t_data_t* t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N14K_form__atom_t t0;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t1;
} _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N13Ast__binary_t_data_t* t0;
   struct _fx_N14K_form__atom_t t1;
   struct _fx_N14K_form__atom_t t2;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t3;
} _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N12Ast__unary_t t0;
   struct _fx_N14K_form__atom_t t1;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t2;
} _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_LN14K_form__atom_t_data_t {
   int_ rc;
   struct _fx_LN14K_form__atom_t_data_t* tl;
   struct _fx_N14K_form__atom_t hd;
} _fx_LN14K_form__atom_t_data_t, *_fx_LN14K_form__atom_t;

typedef struct _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N13Ast__intrin_t t0;
   struct _fx_LN14K_form__atom_t_data_t* t1;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t2;
} _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T2R9Ast__id_tN14K_form__kexp_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
} _fx_T2R9Ast__id_tN14K_form__kexp_t;

typedef struct _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_LN14K_form__kexp_t_data_t* t0;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t1;
} _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N14K_form__kexp_t_data_t* t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
   struct _fx_N14K_form__kexp_t_data_t* t2;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t3;
} _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_LN14K_form__atom_t_data_t* t1;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t2;
} _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   int_ t1;
   struct _fx_LN14K_form__atom_t_data_t* t2;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t3;
} _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_LN14K_form__atom_t_data_t* t0;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t1;
} _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_R9Ast__id_t t1;
   struct _fx_LN14K_form__atom_t_data_t* t2;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t3;
} _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_LLT2BN14K_form__atom_t_data_t {
   int_ rc;
   struct _fx_LLT2BN14K_form__atom_t_data_t* tl;
   struct _fx_LT2BN14K_form__atom_t_data_t* hd;
} _fx_LLT2BN14K_form__atom_t_data_t, *_fx_LLT2BN14K_form__atom_t;

typedef struct _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   bool t0;
   struct _fx_LLT2BN14K_form__atom_t_data_t* t1;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t2;
} _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_LT2BN14K_form__atom_t_data_t* t0;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t1;
} _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_LN13K_form__dom_t_data_t {
   int_ rc;
   struct _fx_LN13K_form__dom_t_data_t* tl;
   struct _fx_N13K_form__dom_t hd;
} _fx_LN13K_form__dom_t_data_t, *_fx_LN13K_form__dom_t;

typedef struct _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N14K_form__atom_t t0;
   struct _fx_N13Ast__border_t t1;
   struct _fx_N18Ast__interpolate_t t2;
   struct _fx_LN13K_form__dom_t_data_t* t3;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t4;
} _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   int_ t1;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t2;
} _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14K_form__atom_t t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t;

typedef struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t {
   struct _fx_LN14K_form__kexp_t_data_t* t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
} _fx_T2LN14K_form__kexp_tN14K_form__kexp_t;

typedef struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t {
   int_ rc;
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t* tl;
   struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t hd;
} _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t, *_fx_LT2LN14K_form__kexp_tN14K_form__kexp_t;

typedef struct _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t* t0;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t1;
} _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N14K_form__kexp_t_data_t* t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t2;
} _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3R9Ast__id_tBR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   bool t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3R9Ast__id_tBR10Ast__loc_t;

typedef struct _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_N14K_form__atom_t t0;
   struct _fx_N14K_form__ktyp_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T2R9Ast__id_tN13K_form__dom_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N13K_form__dom_t t1;
} _fx_T2R9Ast__id_tN13K_form__dom_t;

typedef struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t {
   int_ rc;
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* tl;
   struct _fx_T2R9Ast__id_tN13K_form__dom_t hd;
} _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t, *_fx_LT2R9Ast__id_tN13K_form__dom_t;

typedef struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t {
   struct _fx_N14K_form__kexp_t_data_t* t0;
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t1;
   struct _fx_LR9Ast__id_t_data_t* t2;
} _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t;

typedef struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t {
   int_ rc;
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* tl;
   struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t hd;
} _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t, *_fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t;

typedef struct _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t {
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
   struct _fx_R16Ast__for_flags_t t2;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t3;
} _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t {
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t0;
   struct _fx_LR9Ast__id_t_data_t* t1;
   struct _fx_N14K_form__kexp_t_data_t* t2;
   struct _fx_R16Ast__for_flags_t t3;
   struct _fx_R10Ast__loc_t t4;
} _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t;

typedef struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t {
   struct _fx_N14K_form__kexp_t_data_t* t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t;

typedef struct _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t {
   fx_str_t t0;
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t t1;
} _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t;

typedef struct _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t;

typedef struct _fx_N14K_form__kexp_t_data_t {
   int_ rc;
   int tag;
   union {
      struct _fx_R10Ast__loc_t KExpNop;
      struct _fx_R10Ast__loc_t KExpBreak;
      struct _fx_R10Ast__loc_t KExpContinue;
      struct _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t KExpReturn;
      struct _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpAtom;
      struct _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpBinary;
      struct _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpUnary;
      struct _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpIntrin;
      struct _fx_T2R9Ast__id_tN14K_form__kexp_t KExpSync;
      struct _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t KExpSeq;
      struct _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t KExpIf;
      struct _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpCall;
      struct _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpICall;
      struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpMkTuple;
      struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpMkRecord;
      struct _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpMkClosure;
      struct _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpMkArray;
      struct _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t KExpMkVector;
      struct _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t
         KExpAt;
      struct _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t KExpMem;
      struct _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t KExpAssign;
      struct _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t KExpMatch;
      struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t KExpTryCatch;
      struct _fx_T3R9Ast__id_tBR10Ast__loc_t KExpThrow;
      struct _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t KExpCast;
      struct _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t
         KExpMap;
      struct _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t KExpFor;
      struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t KExpWhile;
      struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t KExpDoWhile;
      struct _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t KExpCCode;
      struct _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t KDefVal;
      struct _fx_rR17K_form__kdeffun_t_data_t* KDefFun;
      struct _fx_rR17K_form__kdefexn_t_data_t* KDefExn;
      struct _fx_rR21K_form__kdefvariant_t_data_t* KDefVariant;
      struct _fx_rR23K_form__kdefinterface_t_data_t* KDefInterface;
      struct _fx_rR17K_form__kdeftyp_t_data_t* KDefTyp;
      struct _fx_rR25K_form__kdefclosurevars_t_data_t* KDefClosureVars;
   } u;
} _fx_N14K_form__kexp_t_data_t, *_fx_N14K_form__kexp_t;

typedef struct _fx_R17K_form__kmodule_t {
   struct _fx_R9Ast__id_t km_name;
   int_ km_idx;
   int_ km_toposort_idx;
   fx_str_t km_cname;
   struct _fx_LN14K_form__kexp_t_data_t* km_top;
   struct _fx_Li_data_t* km_deps;
   bool km_skip;
   bool km_main;
   struct _fx_R14Ast__pragmas_t km_pragmas;
} _fx_R17K_form__kmodule_t;

typedef struct _fx_LR17K_form__kmodule_t_data_t {
   int_ rc;
   struct _fx_LR17K_form__kmodule_t_data_t* tl;
   struct _fx_R17K_form__kmodule_t hd;
} _fx_LR17K_form__kmodule_t_data_t, *_fx_LR17K_form__kmodule_t;

typedef struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t {
   int_ rc;
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* data;
} _fx_rNt10Hashset__t1R9Ast__id_t_data_t, *_fx_rNt10Hashset__t1R9Ast__id_t;

typedef struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti {
   uint64_t hv;
   struct _fx_R9Ast__id_t key;
   int_ data;
} _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti;

typedef struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti {
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti t0;
   int_ t1;
   int_ t2;
   int_ t3;
   fx_arr_t t4;
   fx_arr_t t5;
} _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti;

typedef struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t {
   int_ rc;
   union {
      struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti t;
   } u;
} _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t, *_fx_Nt10Hashmap__t2R9Ast__id_ti;

typedef struct _fx_Nt6option1rR23C_form__cdefinterface_t {
   int tag;
   union {
      struct _fx_rR23C_form__cdefinterface_t_data_t* Some;
   } u;
} _fx_Nt6option1rR23C_form__cdefinterface_t;

typedef struct _fx_Nt6option1N14C_form__ctyp_t {
   int tag;
   union {
      struct _fx_N14C_form__ctyp_t_data_t* Some;
   } u;
} _fx_Nt6option1N14C_form__ctyp_t;

typedef struct _fx_Nt6option1R9Ast__id_t {
   int tag;
   union {
      struct _fx_R9Ast__id_t Some;
   } u;
} _fx_Nt6option1R9Ast__id_t;

typedef struct _fx_T2R9Ast__id_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2R9Ast__id_tR10Ast__loc_t;

typedef struct _fx_N17C_form__cbinary_t {
   int tag;
   union {
      struct _fx_N12Ast__cmpop_t COpCmp;
   } u;
} _fx_N17C_form__cbinary_t;

typedef struct _fx_N16C_form__cunary_t {
   int tag;
} _fx_N16C_form__cunary_t;

typedef struct _fx_N19C_form__ctyp_attr_t {
   int tag;
} _fx_N19C_form__ctyp_attr_t;

typedef struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t {
   struct _fx_Nt6option1R9Ast__id_t t0;
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* t1;
} _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t;

typedef struct _fx_LN14C_form__ctyp_t_data_t {
   int_ rc;
   struct _fx_LN14C_form__ctyp_t_data_t* tl;
   struct _fx_N14C_form__ctyp_t_data_t* hd;
} _fx_LN14C_form__ctyp_t_data_t, *_fx_LN14C_form__ctyp_t;

typedef struct _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t {
   struct _fx_LN14C_form__ctyp_t_data_t* t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
} _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t;

typedef struct _fx_LN19C_form__ctyp_attr_t_data_t {
   int_ rc;
   struct _fx_LN19C_form__ctyp_attr_t_data_t* tl;
   struct _fx_N19C_form__ctyp_attr_t hd;
} _fx_LN19C_form__ctyp_attr_t_data_t, *_fx_LN19C_form__ctyp_attr_t;

typedef struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t {
   struct _fx_LN19C_form__ctyp_attr_t_data_t* t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
} _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t;

typedef struct _fx_T2iN14C_form__ctyp_t {
   int_ t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
} _fx_T2iN14C_form__ctyp_t;

typedef struct _fx_N14C_form__ctyp_t_data_t {
   int_ rc;
   int tag;
   union {
      int_ CTypSInt;
      int_ CTypUInt;
      int_ CTypFloat;
      struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t CTypStruct;
      struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t CTypUnion;
      struct _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t CTypFunRawPtr;
      struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t CTypRawPtr;
      struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t CTypRawArray;
      struct _fx_T2iN14C_form__ctyp_t CTypArray;
      struct _fx_N14C_form__ctyp_t_data_t* CTypVector;
      struct _fx_R9Ast__id_t CTypName;
   } u;
} _fx_N14C_form__ctyp_t_data_t, *_fx_N14C_form__ctyp_t;

typedef struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N14C_form__ctyp_t_data_t* t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t1;
} _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N14K_form__klit_t t0;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t1;
} _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N17C_form__cbinary_t t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t3;
} _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N16C_form__cunary_t t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t2;
} _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_R9Ast__id_t t1;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t2;
} _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t3;
} _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_LN14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_LN14C_form__cexp_t_data_t* tl;
   struct _fx_N14C_form__cexp_t_data_t* hd;
} _fx_LN14C_form__cexp_t_data_t, *_fx_LN14C_form__cexp_t;

typedef struct _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t2;
} _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t t1;
} _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t;

typedef struct _fx_N14C_form__cexp_t_data_t {
   int_ rc;
   int tag;
   union {
      struct _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t CExpIdent;
      struct _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t CExpLit;
      struct _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t CExpBinary;
      struct _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t CExpUnary;
      struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t CExpMem;
      struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t CExpArrow;
      struct _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t CExpCast;
      struct _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t CExpTernary;
      struct _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t CExpCall;
      struct _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t CExpInit;
      struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t CExpTyp;
      struct _fx_T2SR10Ast__loc_t CExpCCode;
   } u;
} _fx_N14C_form__cexp_t_data_t, *_fx_N14C_form__cexp_t;

typedef struct _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t {
   struct _fx_Nt6option1N14C_form__cexp_t t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t;

typedef struct _fx_T2LN15C_form__cstmt_tR10Ast__loc_t {
   struct _fx_LN15C_form__cstmt_t_data_t* t0;
   struct _fx_R10Ast__loc_t t1;
} _fx_T2LN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_T2R9Ast__id_tN15C_form__cstmt_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N15C_form__cstmt_t_data_t* t1;
} _fx_T2R9Ast__id_tN15C_form__cstmt_t;

typedef struct _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_N15C_form__cstmt_t_data_t* t1;
   struct _fx_N15C_form__cstmt_t_data_t* t2;
   struct _fx_R10Ast__loc_t t3;
} _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t {
   struct _fx_Nt6option1N14C_form__ctyp_t t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_Nt6option1N14C_form__cexp_t t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
   struct _fx_N15C_form__cstmt_t_data_t* t4;
   struct _fx_R10Ast__loc_t t5;
} _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_N15C_form__cstmt_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t {
   struct _fx_N15C_form__cstmt_t_data_t* t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t;

typedef struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t {
   int_ rc;
   struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t* tl;
   struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t hd;
} _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t, *_fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t {
   struct _fx_N14C_form__ctyp_t_data_t* t0;
   struct _fx_R9Ast__id_t t1;
   struct _fx_Nt6option1N14C_form__cexp_t t2;
   struct _fx_R10Ast__loc_t t3;
} _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t;

typedef struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t {
   int_ rc;
   struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t* tl;
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t hd;
} _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t, *_fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t {
   struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_N15C_form__cstmt_t_data_t {
   int_ rc;
   int tag;
   union {
      struct _fx_R10Ast__loc_t CStmtNop;
      struct _fx_T2SR10Ast__loc_t CComment;
      struct _fx_N14C_form__cexp_t_data_t* CExp;
      struct _fx_R10Ast__loc_t CStmtBreak;
      struct _fx_R10Ast__loc_t CStmtContinue;
      struct _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t CStmtReturn;
      struct _fx_T2LN15C_form__cstmt_tR10Ast__loc_t CStmtBlock;
      struct _fx_T2R9Ast__id_tN15C_form__cstmt_t CStmtSync;
      struct _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t CStmtIf;
      struct _fx_T2R9Ast__id_tR10Ast__loc_t CStmtGoto;
      struct _fx_T2R9Ast__id_tR10Ast__loc_t CStmtLabel;
      struct _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t
         CStmtFor;
      struct _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t CStmtWhile;
      struct _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t CStmtDoWhile;
      struct _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t CStmtSwitch;
      struct _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t CDefVal;
      struct _fx_rR17C_form__cdeffun_t_data_t* CDefFun;
      struct _fx_rR17C_form__cdeftyp_t_data_t* CDefTyp;
      struct _fx_T2R9Ast__id_tR10Ast__loc_t CDefForwardSym;
      struct _fx_T2R9Ast__id_tR10Ast__loc_t CDefForwardTyp;
      struct _fx_rR18C_form__cdefenum_t_data_t* CDefEnum;
      struct _fx_rR23C_form__cdefinterface_t_data_t* CDefInterface;
      struct _fx_rR19C_form__cdefmacro_t_data_t* CMacroDef;
      struct _fx_T2R9Ast__id_tR10Ast__loc_t CMacroUndef;
      struct _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t CMacroIf;
      struct _fx_T2SR10Ast__loc_t CMacroInclude;
      struct _fx_T2SR10Ast__loc_t CMacroPragma;
   } u;
} _fx_N15C_form__cstmt_t_data_t, *_fx_N15C_form__cstmt_t;

typedef struct _fx_T2SR9Ast__id_t {
   fx_str_t t0;
   struct _fx_R9Ast__id_t t1;
} _fx_T2SR9Ast__id_t;

typedef struct _fx_T2BNt6option1N14C_form__cexp_t {
   bool t0;
   struct _fx_Nt6option1N14C_form__cexp_t t1;
} _fx_T2BNt6option1N14C_form__cexp_t;

typedef struct _fx_Ta3LN15C_form__cstmt_t {
   struct _fx_LN15C_form__cstmt_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_Ta3LN15C_form__cstmt_t;

typedef struct _fx_rLN15C_form__cstmt_t_data_t {
   int_ rc;
   struct _fx_LN15C_form__cstmt_t_data_t* data;
} _fx_rLN15C_form__cstmt_t_data_t, *_fx_rLN15C_form__cstmt_t;

typedef struct _fx_N24C_gen_code__block_kind_t {
   int tag;
   union {
      struct _fx_R9Ast__id_t BlockKind_Fun;
   } u;
} _fx_N24C_gen_code__block_kind_t;

typedef struct _fx_R23C_gen_code__block_ctx_t {
   struct _fx_N24C_gen_code__block_kind_t bctx_kind;
   struct _fx_R9Ast__id_t bctx_label;
   struct _fx_R9Ast__id_t bctx_br_label;
   struct _fx_R16Ast__for_flags_t bctx_for_flags;
   struct _fx_N14C_form__cexp_t_data_t* bctx_status;
   struct _fx_N14C_form__cexp_t_data_t* bctx_par_status;
   struct _fx_LN15C_form__cstmt_t_data_t* bctx_prologue;
   struct _fx_LN15C_form__cstmt_t_data_t* bctx_cleanup;
   int_ bctx_break_used;
   int_ bctx_continue_used;
   int_ bctx_return_used;
   int_ bctx_label_used;
} _fx_R23C_gen_code__block_ctx_t;

typedef struct _fx_rR23C_gen_code__block_ctx_t_data_t {
   int_ rc;
   struct _fx_R23C_gen_code__block_ctx_t data;
} _fx_rR23C_gen_code__block_ctx_t_data_t, *_fx_rR23C_gen_code__block_ctx_t;

typedef struct _fx_Nt6option1rR23C_gen_code__block_ctx_t {
   int tag;
   union {
      struct _fx_rR23C_gen_code__block_ctx_t_data_t* Some;
   } u;
} _fx_Nt6option1rR23C_gen_code__block_ctx_t;

typedef struct _fx_Nt6option1i {
   int tag;
   union {
      int_ Some;
   } u;
} _fx_Nt6option1i;

typedef struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t {
   struct _fx_Nt6option1N14C_form__ctyp_t t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_Nt6option1N14C_form__cexp_t t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
} _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t;

typedef struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* tl;
   struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t hd;
} _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t, *_fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t;

typedef struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t {
   struct _fx_N14C_form__ctyp_t_data_t* t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
   struct _fx_N14C_form__cexp_t_data_t* t3;
   struct _fx_N14C_form__cexp_t_data_t* t4;
} _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t;

typedef struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* tl;
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t hd;
} _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t, *_fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t;

typedef struct _fx_LLN15C_form__cstmt_t_data_t {
   int_ rc;
   struct _fx_LLN15C_form__cstmt_t_data_t* tl;
   struct _fx_LN15C_form__cstmt_t_data_t* hd;
} _fx_LLN15C_form__cstmt_t_data_t, *_fx_LLN15C_form__cstmt_t;

typedef struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t {
   uint64_t hv;
   struct _fx_R9Ast__id_t key;
   struct _fx_N14C_form__cexp_t_data_t* data;
} _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t;

typedef struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t {
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t t0;
   int_ t1;
   int_ t2;
   int_ t3;
   fx_arr_t t4;
   fx_arr_t t5;
} _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t;

typedef struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t {
   int_ rc;
   union {
      struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t
         t;
   } u;
} _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t, *_fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t;

typedef struct _fx_R17C_form__cmodule_t {
   struct _fx_R9Ast__id_t cmod_name;
   fx_str_t cmod_cname;
   struct _fx_LN15C_form__cstmt_t_data_t* cmod_ccode;
   bool cmod_main;
   bool cmod_recompile;
   bool cmod_skip;
   struct _fx_R14Ast__pragmas_t cmod_pragmas;
} _fx_R17C_form__cmodule_t;

typedef struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t {
   int_ rc;
   struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t* data;
} _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t, *_fx_rNt10Hashmap__t2R9Ast__id_ti;

typedef struct _fx_Ta3LS {
   struct _fx_LS_data_t* t0;
   struct _fx_LS_data_t* t1;
   struct _fx_LS_data_t* t2;
} _fx_Ta3LS;

typedef struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* t2;
   int_ t3;
} _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti;

typedef struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB {
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0;
   struct _fx_R9Ast__id_t t1;
   struct _fx_N14C_form__ctyp_t_data_t* t2;
   bool t3;
} _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB;

typedef struct _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB {
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0;
   bool t1;
} _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB;

typedef struct _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t {
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0;
   struct _fx_R9Ast__id_t t1;
   struct _fx_N14C_form__ctyp_t_data_t* t2;
} _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t;

typedef struct _fx_Ta3N14C_form__cexp_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
} _fx_Ta3N14C_form__cexp_t;

typedef struct _fx_T2N14C_form__cexp_tN14C_form__ctyp_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
} _fx_T2N14C_form__cexp_tN14C_form__ctyp_t;

typedef struct _fx_LR17C_form__cmodule_t_data_t {
   int_ rc;
   struct _fx_LR17C_form__cmodule_t_data_t* tl;
   struct _fx_R17C_form__cmodule_t hd;
} _fx_LR17C_form__cmodule_t_data_t, *_fx_LR17C_form__cmodule_t;

typedef struct _fx_Ta2LN15C_form__cstmt_t {
   struct _fx_LN15C_form__cstmt_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_Ta2LN15C_form__cstmt_t;

typedef struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* data;
} _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t, *_fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t;

typedef struct _fx_LrR23C_gen_code__block_ctx_t_data_t {
   int_ rc;
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t* tl;
   struct _fx_rR23C_gen_code__block_ctx_t_data_t* hd;
} _fx_LrR23C_gen_code__block_ctx_t_data_t, *_fx_LrR23C_gen_code__block_ctx_t;

typedef struct _fx_rLrR23C_gen_code__block_ctx_t_data_t {
   int_ rc;
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t* data;
} _fx_rLrR23C_gen_code__block_ctx_t_data_t, *_fx_rLrR23C_gen_code__block_ctx_t;

typedef struct _fx_rNt6option1N14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_Nt6option1N14C_form__cexp_t data;
} _fx_rNt6option1N14C_form__cexp_t_data_t, *_fx_rNt6option1N14C_form__cexp_t;

typedef struct _fx_rrNt6option1N14C_form__cexp_t_data_t {
   int_ rc;
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* data;
} _fx_rrNt6option1N14C_form__cexp_t_data_t, *_fx_rrNt6option1N14C_form__cexp_t;

typedef struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t {
   int (*fp)(
      struct _fx_N14K_form__kexp_t_data_t*, struct _fx_rNt6option1N14C_form__cexp_t_data_t*,
         struct _fx_LN15C_form__cstmt_t_data_t*, struct _fx_rLrR23C_gen_code__block_ctx_t_data_t*,
         struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t*, struct _fx_LS_data_t*,
         struct _fx_rrNt6option1N14C_form__cexp_t_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_R9Ast__id_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t*, int_,
         struct _fx_LN12Ast__scope_t_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_ri_data_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t*,
         struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t;

typedef struct _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t {
   bool t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_N14C_form__ctyp_t_data_t* t2;
} _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t;

typedef struct _fx_T2R9Ast__id_tLN15C_form__cstmt_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_T2R9Ast__id_tLN15C_form__cstmt_t;

typedef struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t {
   int (*fp)(
      struct _fx_N14K_form__atom_t*, bool, struct _fx_LN15C_form__cstmt_t_data_t*, struct _fx_R10Ast__loc_t*,
         struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t;

typedef struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti {
   int (*fp)(
      struct _fx_N14K_form__atom_t*, struct _fx_LN15C_form__cstmt_t_data_t*, struct _fx_R10Ast__loc_t*,
         struct _fx_rLrR23C_gen_code__block_ctx_t_data_t*, struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t*, int_,
         struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti;

typedef struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_R16Ast__val_flags_t t2;
} _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t;

typedef struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t {
   int_ rc;
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* tl;
   struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t hd;
} _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t, *_fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t;

typedef struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t {
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
   struct _fx_LN15C_form__cstmt_t_data_t* t4;
   struct _fx_LN15C_form__cstmt_t_data_t* t5;
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* t6;
   struct _fx_LN15C_form__cstmt_t_data_t* t7;
} _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t;

typedef struct _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t {
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t0;
   struct _fx_LR9Ast__id_t_data_t* t1;
} _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t;

typedef struct _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
   struct _fx_LN14C_form__cexp_t_data_t* t4;
   struct _fx_LN14C_form__cexp_t_data_t* t5;
   struct _fx_LN15C_form__cstmt_t_data_t* t6;
   struct _fx_LN15C_form__cstmt_t_data_t* t7;
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* t8;
   struct _fx_LN14C_form__cexp_t_data_t* t9;
} _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t;

typedef struct _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_N17C_form__cbinary_t t0;
   struct _fx_N17C_form__cbinary_t t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
   struct _fx_LN15C_form__cstmt_t_data_t* t3;
} _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t {
   bool t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
   struct _fx_LN14C_form__cexp_t_data_t* t4;
   struct _fx_LN15C_form__cstmt_t_data_t* t5;
} _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T2BR9Ast__id_t {
   bool t0;
   struct _fx_R9Ast__id_t t1;
} _fx_T2BR9Ast__id_t;

typedef struct _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
   struct _fx_LN15C_form__cstmt_t_data_t* t4;
} _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   struct _fx_LN15C_form__cstmt_t_data_t* t3;
} _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t {
   int_ t0;
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* t1;
} _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t;

typedef struct _fx_T2N14C_form__cexp_tLN14C_form__cexp_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
} _fx_T2N14C_form__cexp_tLN14C_form__cexp_t;

typedef struct _fx_FPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti {
   int (*fp)(
      struct _fx_N14C_form__cexp_t_data_t*, struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t*, struct _fx_LR9Ast__id_t_data_t*,
         int_, int_, int_, int_, struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t*,
         struct _fx_LN15C_form__cstmt_t_data_t*, struct _fx_R10Ast__loc_t*, struct _fx_rLrR23C_gen_code__block_ctx_t_data_t*,
         struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t*, struct _fx_LS_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*,
         struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t*, int_,
         struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*,
         void*);
   fx_fcv_t* fcv;
} _fx_FPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti;

typedef struct _fx_T5BBBBLLN15C_form__cstmt_t {
   bool t0;
   bool t1;
   bool t2;
   bool t3;
   struct _fx_LLN15C_form__cstmt_t_data_t* t4;
} _fx_T5BBBBLLN15C_form__cstmt_t;

typedef struct _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_LLN15C_form__cstmt_t_data_t* t1;
} _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t;

typedef struct _fx_T3LN15C_form__cstmt_tBB {
   struct _fx_LN15C_form__cstmt_t_data_t* t0;
   bool t1;
   bool t2;
} _fx_T3LN15C_form__cstmt_tBB;

typedef struct _fx_T2BLN15C_form__cstmt_t {
   bool t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_T2BLN15C_form__cstmt_t;

typedef struct _fx_FPLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t {
   int (*fp)(
      struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t*, struct _fx_rNt6option1N14C_form__cexp_t_data_t*,
         struct _fx_LN15C_form__cstmt_t_data_t*, bool, struct _fx_R10Ast__loc_t*,
         struct _fx_rLrR23C_gen_code__block_ctx_t_data_t*, struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t*,
         struct _fx_LS_data_t*, struct _fx_rrNt6option1N14C_form__cexp_t_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*,
         struct _fx_R9Ast__id_t*, struct _fx_rLN15C_form__cstmt_t_data_t*,
         struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t*, int_, struct _fx_LN12Ast__scope_t_data_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_ri_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*,
         struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t*, struct _fx_LN15C_form__cstmt_t_data_t**, void*);
   fx_fcv_t* fcv;
} _fx_FPLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t;

typedef struct _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t {
   bool t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_Ta2B {
   bool t0;
   bool t1;
} _fx_Ta2B;

typedef struct _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t {
   bool t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
   struct _fx_N14C_form__ctyp_t_data_t* t3;
   struct _fx_R9Ast__id_t t4;
} _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t;

typedef struct _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t {
   bool t0;
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t t1;
} _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t {
   struct _fx_N17C_form__cbinary_t t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
} _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t;

typedef struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t {
   int (*fp)(
      struct _fx_LN14K_form__kexp_t_data_t*, struct _fx_LN15C_form__cstmt_t_data_t*,
         struct _fx_rLrR23C_gen_code__block_ctx_t_data_t*, struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t*,
         struct _fx_rNt6option1N14C_form__cexp_t_data_t*, struct _fx_N14C_form__cexp_t_data_t*, struct _fx_LS_data_t*,
         struct _fx_rrNt6option1N14C_form__cexp_t_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_R9Ast__id_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t*, int_,
         struct _fx_LN12Ast__scope_t_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_ri_data_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t*,
         struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t;

typedef struct _fx_T2R9Ast__id_tN15C_form__cinfo_t {
   struct _fx_R9Ast__id_t t0;
   struct _fx_N15C_form__cinfo_t t1;
} _fx_T2R9Ast__id_tN15C_form__cinfo_t;

typedef struct _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   bool t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   bool t3;
   struct _fx_LN15C_form__cstmt_t_data_t* t4;
} _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t;

typedef struct _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_LN14C_form__cexp_t_data_t* t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T2LN14K_form__atom_tS {
   struct _fx_LN14K_form__atom_t_data_t* t0;
   fx_str_t t1;
} _fx_T2LN14K_form__atom_tS;

typedef struct _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t {
   int_ t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN14C_form__cexp_t_data_t* t2;
   struct _fx_LN14C_form__cexp_t_data_t* t3;
   struct _fx_LN15C_form__cstmt_t_data_t* t4;
} _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T2iN14C_form__cexp_t {
   int_ t0;
   struct _fx_N14C_form__cexp_t_data_t* t1;
} _fx_T2iN14C_form__cexp_t;

typedef struct _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t {
   int_ t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
} _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t;

typedef struct _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t {
   int_ t0;
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t t1;
} _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_Nt6option1N14C_form__cexp_t t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_Ta2N14K_form__kexp_t {
   struct _fx_N14K_form__kexp_t_data_t* t0;
   struct _fx_N14K_form__kexp_t_data_t* t1;
} _fx_Ta2N14K_form__kexp_t;

typedef struct _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
   struct _fx_N14C_form__cexp_t_data_t* t2;
   struct _fx_LN15C_form__cstmt_t_data_t* t3;
} _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t {
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t;

typedef struct _fx_FPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrR23C_gen_code__block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB {
   int (*fp)(
      struct _fx_LN15C_form__cstmt_t_data_t*, int_,
         struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t*,
         struct _fx_LN14C_form__cexp_t_data_t*, struct _fx_LN14C_form__cexp_t_data_t*,
         struct _fx_rLrR23C_gen_code__block_ctx_t_data_t*, struct _fx_LN15C_form__cstmt_t_data_t*,
         struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t*,
         struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t*,
         struct _fx_R10Ast__loc_t*, struct _fx_N15Ast__for_make_t*, struct _fx_LS_data_t*, struct _fx_R10Ast__loc_t*,
         struct _fx_rrNt6option1N14C_form__cexp_t_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_R9Ast__id_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t*, bool,
         struct _fx_R10Ast__loc_t*, int_, struct _fx_N14C_form__cexp_t_data_t*, struct _fx_LN12Ast__scope_t_data_t*,
         struct _fx_rLN15C_form__cstmt_t_data_t*, int_, bool, struct _fx_N14C_form__cexp_t_data_t*, int_,
         struct _fx_N14C_form__cexp_t_data_t*, bool, struct _fx_ri_data_t*, struct _fx_rLN15C_form__cstmt_t_data_t*,
         struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t*, bool, struct _fx_Ta2LN15C_form__cstmt_t*, void*);
   fx_fcv_t* fcv;
} _fx_FPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrR23C_gen_code__block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB;

typedef struct _fx_T3SSR10Ast__loc_t {
   fx_str_t t0;
   fx_str_t t1;
   struct _fx_R10Ast__loc_t t2;
} _fx_T3SSR10Ast__loc_t;

typedef struct _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB {
   struct _fx_R16Ast__val_flags_t t0;
   struct _fx_Nt6option1N14C_form__cexp_t t1;
   bool t2;
} _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB;

typedef struct _fx_T2Nt6option1N14C_form__cexp_tB {
   struct _fx_Nt6option1N14C_form__cexp_t t0;
   bool t1;
} _fx_T2Nt6option1N14C_form__cexp_tB;

typedef struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t {
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0;
   struct _fx_N14C_form__ctyp_t_data_t* t1;
   bool t2;
   struct _fx_rR17C_form__cdeffun_t_data_t* t3;
} _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t;

typedef struct _fx_T3BBR9Ast__id_t {
   bool t0;
   bool t1;
   struct _fx_R9Ast__id_t t2;
} _fx_T3BBR9Ast__id_t;

typedef struct _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t {
   struct _fx_N14C_form__cexp_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t;

typedef struct _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t {
   struct _fx_N14C_form__ctyp_t_data_t* t0;
   struct _fx_R9Ast__id_t t1;
   bool t2;
   struct _fx_R9Ast__id_t t3;
   struct _fx_R9Ast__id_t t4;
} _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t;

typedef struct _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t {
   struct _fx_N14K_form__kexp_t_data_t* t0;
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t1;
   struct _fx_LR9Ast__id_t_data_t* t2;
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* t3;
} _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t;

typedef struct _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t {
   int_ t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
} _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T2iLN14C_form__cexp_t {
   int_ t0;
   struct _fx_LN14C_form__cexp_t_data_t* t1;
} _fx_T2iLN14C_form__cexp_t;

typedef struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t {
   bool t0;
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
   struct _fx_LN15C_form__cstmt_t_data_t* t3;
} _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t;

typedef struct _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t {
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t;

typedef struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t {
   bool t0;
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
   struct _fx_Ta2LN15C_form__cstmt_t t3;
} _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t;

typedef struct _fx_Ta2Nt6option1N14C_form__ctyp_t {
   struct _fx_Nt6option1N14C_form__ctyp_t t0;
   struct _fx_Nt6option1N14C_form__ctyp_t t1;
} _fx_Ta2Nt6option1N14C_form__ctyp_t;

typedef struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t {
   struct _fx_R17K_form__kmodule_t t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
   struct _fx_LN15C_form__cstmt_t_data_t* t2;
   struct _fx_LN15C_form__cstmt_t_data_t* t3;
} _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t;

typedef struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t {
   int_ rc;
   struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t* tl;
   struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t hd;
} _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t, *_fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t;

typedef struct _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t {
   struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t* t0;
   struct _fx_LN15C_form__cstmt_t_data_t* t1;
} _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t;

typedef struct {
   int_ rc;
   int_ data;
} _fx_E4Exit_data_t;

typedef struct {
   int_ rc;
   fx_str_t data;
} _fx_E4Fail_data_t;

typedef struct {
   int_ rc;
   struct _fx_T2Ta2iS data;
} _fx_E22LexerUtils__LexerError_data_t;

typedef struct {
   int_ rc;
   struct _fx_T2R10Ast__loc_tS data;
} _fx_E17Ast__CompileError_data_t;

typedef struct {
   int_ rc;
   struct _fx_T2R10Ast__loc_tS data;
} _fx_E18Parser__ParseError_data_t;

static void _fx_free_LS(struct _fx_LS_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LS, fx_free_str);
}

static int _fx_cons_LS(fx_str_t* hd, struct _fx_LS_data_t* tl, bool addref_tl, struct _fx_LS_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LS, fx_copy_str);
}

static void _fx_free_T2Ta2iS(struct _fx_T2Ta2iS* dst)
{
   fx_free_str(&dst->t1);
}

static void _fx_copy_T2Ta2iS(struct _fx_T2Ta2iS* src, struct _fx_T2Ta2iS* dst)
{
   dst->t0 = src->t0;
   fx_copy_str(&src->t1, &dst->t1);
}

static void _fx_make_T2Ta2iS(struct _fx_Ta2i* t0, fx_str_t* t1, struct _fx_T2Ta2iS* fx_result)
{
   fx_result->t0 = *t0;
   fx_copy_str(t1, &fx_result->t1);
}

static int _fx_cons_LN12Ast__scope_t(
   struct _fx_N12Ast__scope_t* hd,
   struct _fx_LN12Ast__scope_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN12Ast__scope_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN12Ast__scope_t, FX_COPY_SIMPLE_BY_PTR);
}

static void _fx_free_R16Ast__val_flags_t(struct _fx_R16Ast__val_flags_t* dst)
{
   fx_free_list_simple(&dst->val_flag_global);
}

static void _fx_copy_R16Ast__val_flags_t(struct _fx_R16Ast__val_flags_t* src, struct _fx_R16Ast__val_flags_t* dst)
{
   dst->val_flag_arg = src->val_flag_arg;
   dst->val_flag_mutable = src->val_flag_mutable;
   dst->val_flag_temp = src->val_flag_temp;
   dst->val_flag_tempref = src->val_flag_tempref;
   dst->val_flag_private = src->val_flag_private;
   dst->val_flag_subarray = src->val_flag_subarray;
   dst->val_flag_instance = src->val_flag_instance;
   dst->val_flag_method = src->val_flag_method;
   dst->val_flag_ctor = src->val_flag_ctor;
   FX_COPY_PTR(src->val_flag_global, &dst->val_flag_global);
}

static void _fx_make_R16Ast__val_flags_t(
   bool r_val_flag_arg,
   bool r_val_flag_mutable,
   bool r_val_flag_temp,
   bool r_val_flag_tempref,
   bool r_val_flag_private,
   bool r_val_flag_subarray,
   bool r_val_flag_instance,
   struct _fx_T2R9Ast__id_ti* r_val_flag_method,
   int_ r_val_flag_ctor,
   struct _fx_LN12Ast__scope_t_data_t* r_val_flag_global,
   struct _fx_R16Ast__val_flags_t* fx_result)
{
   fx_result->val_flag_arg = r_val_flag_arg;
   fx_result->val_flag_mutable = r_val_flag_mutable;
   fx_result->val_flag_temp = r_val_flag_temp;
   fx_result->val_flag_tempref = r_val_flag_tempref;
   fx_result->val_flag_private = r_val_flag_private;
   fx_result->val_flag_subarray = r_val_flag_subarray;
   fx_result->val_flag_instance = r_val_flag_instance;
   fx_result->val_flag_method = *r_val_flag_method;
   fx_result->val_flag_ctor = r_val_flag_ctor;
   FX_COPY_PTR(r_val_flag_global, &fx_result->val_flag_global);
}

static void _fx_free_R17C_form__cdefval_t(struct _fx_R17C_form__cdefval_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->cv_typ);
   fx_free_str(&dst->cv_cname);
   _fx_free_R16Ast__val_flags_t(&dst->cv_flags);
}

static void _fx_copy_R17C_form__cdefval_t(struct _fx_R17C_form__cdefval_t* src, struct _fx_R17C_form__cdefval_t* dst)
{
   dst->cv_name = src->cv_name;
   FX_COPY_PTR(src->cv_typ, &dst->cv_typ);
   fx_copy_str(&src->cv_cname, &dst->cv_cname);
   _fx_copy_R16Ast__val_flags_t(&src->cv_flags, &dst->cv_flags);
   dst->cv_loc = src->cv_loc;
}

static void _fx_make_R17C_form__cdefval_t(
   struct _fx_R9Ast__id_t* r_cv_name,
   struct _fx_N14C_form__ctyp_t_data_t* r_cv_typ,
   fx_str_t* r_cv_cname,
   struct _fx_R16Ast__val_flags_t* r_cv_flags,
   struct _fx_R10Ast__loc_t* r_cv_loc,
   struct _fx_R17C_form__cdefval_t* fx_result)
{
   fx_result->cv_name = *r_cv_name;
   FX_COPY_PTR(r_cv_typ, &fx_result->cv_typ);
   fx_copy_str(r_cv_cname, &fx_result->cv_cname);
   _fx_copy_R16Ast__val_flags_t(r_cv_flags, &fx_result->cv_flags);
   fx_result->cv_loc = *r_cv_loc;
}

static void _fx_free_R19C_form__cdeflabel_t(struct _fx_R19C_form__cdeflabel_t* dst)
{
   fx_free_str(&dst->cl_cname);
}

static void _fx_copy_R19C_form__cdeflabel_t(struct _fx_R19C_form__cdeflabel_t* src, struct _fx_R19C_form__cdeflabel_t* dst)
{
   dst->cl_name = src->cl_name;
   fx_copy_str(&src->cl_cname, &dst->cl_cname);
   dst->cl_loc = src->cl_loc;
}

static void _fx_make_R19C_form__cdeflabel_t(
   struct _fx_R9Ast__id_t* r_cl_name,
   fx_str_t* r_cl_cname,
   struct _fx_R10Ast__loc_t* r_cl_loc,
   struct _fx_R19C_form__cdeflabel_t* fx_result)
{
   fx_result->cl_name = *r_cl_name;
   fx_copy_str(r_cl_cname, &fx_result->cl_cname);
   fx_result->cl_loc = *r_cl_loc;
}

static void _fx_free_T2R9Ast__id_tN14C_form__ctyp_t(struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* src,
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2R9Ast__id_tN14C_form__ctyp_t, _fx_free_T2R9Ast__id_tN14C_form__ctyp_t);
}

static int _fx_cons_LT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* hd,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2R9Ast__id_tN14C_form__ctyp_t, _fx_copy_T2R9Ast__id_tN14C_form__ctyp_t);
}

static void _fx_free_R23C_form__cdefinterface_t(struct _fx_R23C_form__cdefinterface_t* dst)
{
   fx_free_str(&dst->ci_cname);
   _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&dst->ci_all_methods);
   fx_free_list_simple(&dst->ci_scope);
}

static void _fx_copy_R23C_form__cdefinterface_t(
   struct _fx_R23C_form__cdefinterface_t* src,
   struct _fx_R23C_form__cdefinterface_t* dst)
{
   dst->ci_name = src->ci_name;
   fx_copy_str(&src->ci_cname, &dst->ci_cname);
   dst->ci_id = src->ci_id;
   dst->ci_vtbl = src->ci_vtbl;
   dst->ci_base = src->ci_base;
   FX_COPY_PTR(src->ci_all_methods, &dst->ci_all_methods);
   FX_COPY_PTR(src->ci_scope, &dst->ci_scope);
   dst->ci_loc = src->ci_loc;
}

static void _fx_make_R23C_form__cdefinterface_t(
   struct _fx_R9Ast__id_t* r_ci_name,
   fx_str_t* r_ci_cname,
   struct _fx_R9Ast__id_t* r_ci_id,
   struct _fx_R9Ast__id_t* r_ci_vtbl,
   struct _fx_R9Ast__id_t* r_ci_base,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* r_ci_all_methods,
   struct _fx_LN12Ast__scope_t_data_t* r_ci_scope,
   struct _fx_R10Ast__loc_t* r_ci_loc,
   struct _fx_R23C_form__cdefinterface_t* fx_result)
{
   fx_result->ci_name = *r_ci_name;
   fx_copy_str(r_ci_cname, &fx_result->ci_cname);
   fx_result->ci_id = *r_ci_id;
   fx_result->ci_vtbl = *r_ci_vtbl;
   fx_result->ci_base = *r_ci_base;
   FX_COPY_PTR(r_ci_all_methods, &fx_result->ci_all_methods);
   FX_COPY_PTR(r_ci_scope, &fx_result->ci_scope);
   fx_result->ci_loc = *r_ci_loc;
}

static void _fx_free_rR23C_form__cdefinterface_t(struct _fx_rR23C_form__cdefinterface_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR23C_form__cdefinterface_t, _fx_free_R23C_form__cdefinterface_t);
}

static int _fx_make_rR23C_form__cdefinterface_t(
   struct _fx_R23C_form__cdefinterface_t* arg,
   struct _fx_rR23C_form__cdefinterface_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR23C_form__cdefinterface_t, _fx_copy_R23C_form__cdefinterface_t);
}

static void _fx_free_LN15C_form__cstmt_t(struct _fx_LN15C_form__cstmt_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN15C_form__cstmt_t, _fx_free_N15C_form__cstmt_t);
}

static int _fx_cons_LN15C_form__cstmt_t(
   struct _fx_N15C_form__cstmt_t_data_t* hd,
   struct _fx_LN15C_form__cstmt_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN15C_form__cstmt_t, FX_COPY_PTR);
}

static int _fx_cons_LN19C_form__carg_attr_t(
   struct _fx_N19C_form__carg_attr_t* hd,
   struct _fx_LN19C_form__carg_attr_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN19C_form__carg_attr_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN19C_form__carg_attr_t, FX_COPY_SIMPLE_BY_PTR);
}

static void _fx_free_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t1);
   fx_free_list_simple(&dst->t2);
}

static void _fx_copy_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* src,
   struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_LN19C_form__carg_attr_t_data_t* t2,
   struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t,
      _fx_free_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t);
}

static int _fx_cons_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* hd,
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t,
      _fx_copy_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t);
}

static void _fx_free_R17C_form__cdeffun_t(struct _fx_R17C_form__cdeffun_t* dst)
{
   fx_free_str(&dst->cf_cname);
   _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&dst->cf_args);
   _fx_free_N14C_form__ctyp_t(&dst->cf_rt);
   _fx_free_LN15C_form__cstmt_t(&dst->cf_body);
   fx_free_list_simple(&dst->cf_scope);
}

static void _fx_copy_R17C_form__cdeffun_t(struct _fx_R17C_form__cdeffun_t* src, struct _fx_R17C_form__cdeffun_t* dst)
{
   dst->cf_name = src->cf_name;
   fx_copy_str(&src->cf_cname, &dst->cf_cname);
   FX_COPY_PTR(src->cf_args, &dst->cf_args);
   FX_COPY_PTR(src->cf_rt, &dst->cf_rt);
   FX_COPY_PTR(src->cf_body, &dst->cf_body);
   dst->cf_flags = src->cf_flags;
   FX_COPY_PTR(src->cf_scope, &dst->cf_scope);
   dst->cf_loc = src->cf_loc;
}

static void _fx_make_R17C_form__cdeffun_t(
   struct _fx_R9Ast__id_t* r_cf_name,
   fx_str_t* r_cf_cname,
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* r_cf_args,
   struct _fx_N14C_form__ctyp_t_data_t* r_cf_rt,
   struct _fx_LN15C_form__cstmt_t_data_t* r_cf_body,
   struct _fx_R16Ast__fun_flags_t* r_cf_flags,
   struct _fx_LN12Ast__scope_t_data_t* r_cf_scope,
   struct _fx_R10Ast__loc_t* r_cf_loc,
   struct _fx_R17C_form__cdeffun_t* fx_result)
{
   fx_result->cf_name = *r_cf_name;
   fx_copy_str(r_cf_cname, &fx_result->cf_cname);
   FX_COPY_PTR(r_cf_args, &fx_result->cf_args);
   FX_COPY_PTR(r_cf_rt, &fx_result->cf_rt);
   FX_COPY_PTR(r_cf_body, &fx_result->cf_body);
   fx_result->cf_flags = *r_cf_flags;
   FX_COPY_PTR(r_cf_scope, &fx_result->cf_scope);
   fx_result->cf_loc = *r_cf_loc;
}

static void _fx_free_rR17C_form__cdeffun_t(struct _fx_rR17C_form__cdeffun_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR17C_form__cdeffun_t, _fx_free_R17C_form__cdeffun_t);
}

static int _fx_make_rR17C_form__cdeffun_t(
   struct _fx_R17C_form__cdeffun_t* arg,
   struct _fx_rR17C_form__cdeffun_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR17C_form__cdeffun_t, _fx_copy_R17C_form__cdeffun_t);
}

static int _fx_cons_LR9Ast__id_t(
   struct _fx_R9Ast__id_t* hd,
   struct _fx_LR9Ast__id_t_data_t* tl,
   bool addref_tl,
   struct _fx_LR9Ast__id_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LR9Ast__id_t, FX_COPY_SIMPLE_BY_PTR);
}

static void _fx_free_R17C_form__ctprops_t(struct _fx_R17C_form__ctprops_t* dst)
{
   fx_free_list_simple(&dst->ctp_make);
}

static void _fx_copy_R17C_form__ctprops_t(struct _fx_R17C_form__ctprops_t* src, struct _fx_R17C_form__ctprops_t* dst)
{
   dst->ctp_scalar = src->ctp_scalar;
   dst->ctp_complex = src->ctp_complex;
   dst->ctp_ptr = src->ctp_ptr;
   dst->ctp_pass_by_ref = src->ctp_pass_by_ref;
   FX_COPY_PTR(src->ctp_make, &dst->ctp_make);
   dst->ctp_free = src->ctp_free;
   dst->ctp_copy = src->ctp_copy;
}

static void _fx_make_R17C_form__ctprops_t(
   bool r_ctp_scalar,
   bool r_ctp_complex,
   bool r_ctp_ptr,
   bool r_ctp_pass_by_ref,
   struct _fx_LR9Ast__id_t_data_t* r_ctp_make,
   struct _fx_Ta2R9Ast__id_t* r_ctp_free,
   struct _fx_Ta2R9Ast__id_t* r_ctp_copy,
   struct _fx_R17C_form__ctprops_t* fx_result)
{
   fx_result->ctp_scalar = r_ctp_scalar;
   fx_result->ctp_complex = r_ctp_complex;
   fx_result->ctp_ptr = r_ctp_ptr;
   fx_result->ctp_pass_by_ref = r_ctp_pass_by_ref;
   FX_COPY_PTR(r_ctp_make, &fx_result->ctp_make);
   fx_result->ctp_free = *r_ctp_free;
   fx_result->ctp_copy = *r_ctp_copy;
}

static void _fx_free_R17C_form__cdeftyp_t(struct _fx_R17C_form__cdeftyp_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->ct_typ);
   fx_free_str(&dst->ct_cname);
   _fx_free_R17C_form__ctprops_t(&dst->ct_props);
   fx_free_list_simple(&dst->ct_ifaces);
   fx_free_list_simple(&dst->ct_scope);
}

static void _fx_copy_R17C_form__cdeftyp_t(struct _fx_R17C_form__cdeftyp_t* src, struct _fx_R17C_form__cdeftyp_t* dst)
{
   dst->ct_name = src->ct_name;
   FX_COPY_PTR(src->ct_typ, &dst->ct_typ);
   fx_copy_str(&src->ct_cname, &dst->ct_cname);
   _fx_copy_R17C_form__ctprops_t(&src->ct_props, &dst->ct_props);
   dst->ct_data_start = src->ct_data_start;
   dst->ct_enum = src->ct_enum;
   FX_COPY_PTR(src->ct_ifaces, &dst->ct_ifaces);
   dst->ct_ifaces_id = src->ct_ifaces_id;
   FX_COPY_PTR(src->ct_scope, &dst->ct_scope);
   dst->ct_loc = src->ct_loc;
}

static void _fx_make_R17C_form__cdeftyp_t(
   struct _fx_R9Ast__id_t* r_ct_name,
   struct _fx_N14C_form__ctyp_t_data_t* r_ct_typ,
   fx_str_t* r_ct_cname,
   struct _fx_R17C_form__ctprops_t* r_ct_props,
   int_ r_ct_data_start,
   struct _fx_R9Ast__id_t* r_ct_enum,
   struct _fx_LR9Ast__id_t_data_t* r_ct_ifaces,
   struct _fx_R9Ast__id_t* r_ct_ifaces_id,
   struct _fx_LN12Ast__scope_t_data_t* r_ct_scope,
   struct _fx_R10Ast__loc_t* r_ct_loc,
   struct _fx_R17C_form__cdeftyp_t* fx_result)
{
   fx_result->ct_name = *r_ct_name;
   FX_COPY_PTR(r_ct_typ, &fx_result->ct_typ);
   fx_copy_str(r_ct_cname, &fx_result->ct_cname);
   _fx_copy_R17C_form__ctprops_t(r_ct_props, &fx_result->ct_props);
   fx_result->ct_data_start = r_ct_data_start;
   fx_result->ct_enum = *r_ct_enum;
   FX_COPY_PTR(r_ct_ifaces, &fx_result->ct_ifaces);
   fx_result->ct_ifaces_id = *r_ct_ifaces_id;
   FX_COPY_PTR(r_ct_scope, &fx_result->ct_scope);
   fx_result->ct_loc = *r_ct_loc;
}

static void _fx_free_rR17C_form__cdeftyp_t(struct _fx_rR17C_form__cdeftyp_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR17C_form__cdeftyp_t, _fx_free_R17C_form__cdeftyp_t);
}

static int _fx_make_rR17C_form__cdeftyp_t(
   struct _fx_R17C_form__cdeftyp_t* arg,
   struct _fx_rR17C_form__cdeftyp_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR17C_form__cdeftyp_t, _fx_copy_R17C_form__cdeftyp_t);
}

static void _fx_free_Nt6option1N14C_form__cexp_t(struct _fx_Nt6option1N14C_form__cexp_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_N14C_form__cexp_t(&dst->u.Some); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_Nt6option1N14C_form__cexp_t(
   struct _fx_Nt6option1N14C_form__cexp_t* src,
   struct _fx_Nt6option1N14C_form__cexp_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      FX_COPY_PTR(src->u.Some, &dst->u.Some); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_T2R9Ast__id_tNt6option1N14C_form__cexp_t(struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t* dst)
{
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tNt6option1N14C_form__cexp_t(
   struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t* src,
   struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tNt6option1N14C_form__cexp_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_Nt6option1N14C_form__cexp_t* t1,
   struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t* fx_result)
{
   fx_result->t0 = *t0;
   _fx_copy_Nt6option1N14C_form__cexp_t(t1, &fx_result->t1);
}

static void _fx_free_LT2R9Ast__id_tNt6option1N14C_form__cexp_t(
   struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t, _fx_free_T2R9Ast__id_tNt6option1N14C_form__cexp_t);
}

static int _fx_cons_LT2R9Ast__id_tNt6option1N14C_form__cexp_t(
   struct _fx_T2R9Ast__id_tNt6option1N14C_form__cexp_t* hd,
   struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t, _fx_copy_T2R9Ast__id_tNt6option1N14C_form__cexp_t);
}

static void _fx_free_R18C_form__cdefenum_t(struct _fx_R18C_form__cdefenum_t* dst)
{
   _fx_free_LT2R9Ast__id_tNt6option1N14C_form__cexp_t(&dst->cenum_members);
   fx_free_str(&dst->cenum_cname);
   fx_free_list_simple(&dst->cenum_scope);
}

static void _fx_copy_R18C_form__cdefenum_t(struct _fx_R18C_form__cdefenum_t* src, struct _fx_R18C_form__cdefenum_t* dst)
{
   dst->cenum_name = src->cenum_name;
   FX_COPY_PTR(src->cenum_members, &dst->cenum_members);
   fx_copy_str(&src->cenum_cname, &dst->cenum_cname);
   FX_COPY_PTR(src->cenum_scope, &dst->cenum_scope);
   dst->cenum_loc = src->cenum_loc;
}

static void _fx_make_R18C_form__cdefenum_t(
   struct _fx_R9Ast__id_t* r_cenum_name,
   struct _fx_LT2R9Ast__id_tNt6option1N14C_form__cexp_t_data_t* r_cenum_members,
   fx_str_t* r_cenum_cname,
   struct _fx_LN12Ast__scope_t_data_t* r_cenum_scope,
   struct _fx_R10Ast__loc_t* r_cenum_loc,
   struct _fx_R18C_form__cdefenum_t* fx_result)
{
   fx_result->cenum_name = *r_cenum_name;
   FX_COPY_PTR(r_cenum_members, &fx_result->cenum_members);
   fx_copy_str(r_cenum_cname, &fx_result->cenum_cname);
   FX_COPY_PTR(r_cenum_scope, &fx_result->cenum_scope);
   fx_result->cenum_loc = *r_cenum_loc;
}

static void _fx_free_rR18C_form__cdefenum_t(struct _fx_rR18C_form__cdefenum_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR18C_form__cdefenum_t, _fx_free_R18C_form__cdefenum_t);
}

static int _fx_make_rR18C_form__cdefenum_t(
   struct _fx_R18C_form__cdefenum_t* arg,
   struct _fx_rR18C_form__cdefenum_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR18C_form__cdefenum_t, _fx_copy_R18C_form__cdefenum_t);
}

static void _fx_free_R19C_form__cdefmacro_t(struct _fx_R19C_form__cdefmacro_t* dst)
{
   fx_free_str(&dst->cm_cname);
   fx_free_list_simple(&dst->cm_args);
   _fx_free_LN15C_form__cstmt_t(&dst->cm_body);
   fx_free_list_simple(&dst->cm_scope);
}

static void _fx_copy_R19C_form__cdefmacro_t(struct _fx_R19C_form__cdefmacro_t* src, struct _fx_R19C_form__cdefmacro_t* dst)
{
   dst->cm_name = src->cm_name;
   fx_copy_str(&src->cm_cname, &dst->cm_cname);
   FX_COPY_PTR(src->cm_args, &dst->cm_args);
   FX_COPY_PTR(src->cm_body, &dst->cm_body);
   FX_COPY_PTR(src->cm_scope, &dst->cm_scope);
   dst->cm_loc = src->cm_loc;
}

static void _fx_make_R19C_form__cdefmacro_t(
   struct _fx_R9Ast__id_t* r_cm_name,
   fx_str_t* r_cm_cname,
   struct _fx_LR9Ast__id_t_data_t* r_cm_args,
   struct _fx_LN15C_form__cstmt_t_data_t* r_cm_body,
   struct _fx_LN12Ast__scope_t_data_t* r_cm_scope,
   struct _fx_R10Ast__loc_t* r_cm_loc,
   struct _fx_R19C_form__cdefmacro_t* fx_result)
{
   fx_result->cm_name = *r_cm_name;
   fx_copy_str(r_cm_cname, &fx_result->cm_cname);
   FX_COPY_PTR(r_cm_args, &fx_result->cm_args);
   FX_COPY_PTR(r_cm_body, &fx_result->cm_body);
   FX_COPY_PTR(r_cm_scope, &fx_result->cm_scope);
   fx_result->cm_loc = *r_cm_loc;
}

static void _fx_free_rR19C_form__cdefmacro_t(struct _fx_rR19C_form__cdefmacro_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR19C_form__cdefmacro_t, _fx_free_R19C_form__cdefmacro_t);
}

static int _fx_make_rR19C_form__cdefmacro_t(
   struct _fx_R19C_form__cdefmacro_t* arg,
   struct _fx_rR19C_form__cdefmacro_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR19C_form__cdefmacro_t, _fx_copy_R19C_form__cdefmacro_t);
}

static void _fx_free_R17C_form__cdefexn_t(struct _fx_R17C_form__cdefexn_t* dst)
{
   fx_free_str(&dst->cexn_cname);
   fx_free_str(&dst->cexn_base_cname);
   _fx_free_N14C_form__ctyp_t(&dst->cexn_typ);
   fx_free_list_simple(&dst->cexn_scope);
}

static void _fx_copy_R17C_form__cdefexn_t(struct _fx_R17C_form__cdefexn_t* src, struct _fx_R17C_form__cdefexn_t* dst)
{
   dst->cexn_name = src->cexn_name;
   fx_copy_str(&src->cexn_cname, &dst->cexn_cname);
   fx_copy_str(&src->cexn_base_cname, &dst->cexn_base_cname);
   FX_COPY_PTR(src->cexn_typ, &dst->cexn_typ);
   dst->cexn_std = src->cexn_std;
   dst->cexn_tag = src->cexn_tag;
   dst->cexn_data = src->cexn_data;
   dst->cexn_info = src->cexn_info;
   dst->cexn_make = src->cexn_make;
   FX_COPY_PTR(src->cexn_scope, &dst->cexn_scope);
   dst->cexn_loc = src->cexn_loc;
}

static void _fx_make_R17C_form__cdefexn_t(
   struct _fx_R9Ast__id_t* r_cexn_name,
   fx_str_t* r_cexn_cname,
   fx_str_t* r_cexn_base_cname,
   struct _fx_N14C_form__ctyp_t_data_t* r_cexn_typ,
   bool r_cexn_std,
   struct _fx_R9Ast__id_t* r_cexn_tag,
   struct _fx_R9Ast__id_t* r_cexn_data,
   struct _fx_R9Ast__id_t* r_cexn_info,
   struct _fx_R9Ast__id_t* r_cexn_make,
   struct _fx_LN12Ast__scope_t_data_t* r_cexn_scope,
   struct _fx_R10Ast__loc_t* r_cexn_loc,
   struct _fx_R17C_form__cdefexn_t* fx_result)
{
   fx_result->cexn_name = *r_cexn_name;
   fx_copy_str(r_cexn_cname, &fx_result->cexn_cname);
   fx_copy_str(r_cexn_base_cname, &fx_result->cexn_base_cname);
   FX_COPY_PTR(r_cexn_typ, &fx_result->cexn_typ);
   fx_result->cexn_std = r_cexn_std;
   fx_result->cexn_tag = *r_cexn_tag;
   fx_result->cexn_data = *r_cexn_data;
   fx_result->cexn_info = *r_cexn_info;
   fx_result->cexn_make = *r_cexn_make;
   FX_COPY_PTR(r_cexn_scope, &fx_result->cexn_scope);
   fx_result->cexn_loc = *r_cexn_loc;
}

static void _fx_free_rR17C_form__cdefexn_t(struct _fx_rR17C_form__cdefexn_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR17C_form__cdefexn_t, _fx_free_R17C_form__cdefexn_t);
}

static int _fx_make_rR17C_form__cdefexn_t(
   struct _fx_R17C_form__cdefexn_t* arg,
   struct _fx_rR17C_form__cdefexn_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR17C_form__cdefexn_t, _fx_copy_R17C_form__cdefexn_t);
}

static void _fx_free_N15C_form__cinfo_t(struct _fx_N15C_form__cinfo_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_R17C_form__cdefval_t(&dst->u.CVal); break;
   case 3:
      _fx_free_rR17C_form__cdeffun_t(&dst->u.CFun); break;
   case 4:
      _fx_free_rR17C_form__cdeftyp_t(&dst->u.CTyp); break;
   case 5:
      _fx_free_rR17C_form__cdefexn_t(&dst->u.CExn); break;
   case 6:
      _fx_free_rR23C_form__cdefinterface_t(&dst->u.CInterface); break;
   case 7:
      _fx_free_rR18C_form__cdefenum_t(&dst->u.CEnum); break;
   case 8:
      _fx_free_R19C_form__cdeflabel_t(&dst->u.CLabel); break;
   case 9:
      _fx_free_rR19C_form__cdefmacro_t(&dst->u.CMacro); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_N15C_form__cinfo_t(struct _fx_N15C_form__cinfo_t* src, struct _fx_N15C_form__cinfo_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      _fx_copy_R17C_form__cdefval_t(&src->u.CVal, &dst->u.CVal); break;
   case 3:
      FX_COPY_PTR(src->u.CFun, &dst->u.CFun); break;
   case 4:
      FX_COPY_PTR(src->u.CTyp, &dst->u.CTyp); break;
   case 5:
      FX_COPY_PTR(src->u.CExn, &dst->u.CExn); break;
   case 6:
      FX_COPY_PTR(src->u.CInterface, &dst->u.CInterface); break;
   case 7:
      FX_COPY_PTR(src->u.CEnum, &dst->u.CEnum); break;
   case 8:
      _fx_copy_R19C_form__cdeflabel_t(&src->u.CLabel, &dst->u.CLabel); break;
   case 9:
      FX_COPY_PTR(src->u.CMacro, &dst->u.CMacro); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_R17K_form__kdefval_t(struct _fx_R17K_form__kdefval_t* dst)
{
   fx_free_str(&dst->kv_cname);
   _fx_free_N14K_form__ktyp_t(&dst->kv_typ);
   _fx_free_R16Ast__val_flags_t(&dst->kv_flags);
}

static void _fx_copy_R17K_form__kdefval_t(struct _fx_R17K_form__kdefval_t* src, struct _fx_R17K_form__kdefval_t* dst)
{
   dst->kv_name = src->kv_name;
   fx_copy_str(&src->kv_cname, &dst->kv_cname);
   FX_COPY_PTR(src->kv_typ, &dst->kv_typ);
   _fx_copy_R16Ast__val_flags_t(&src->kv_flags, &dst->kv_flags);
   dst->kv_loc = src->kv_loc;
}

static void _fx_make_R17K_form__kdefval_t(
   struct _fx_R9Ast__id_t* r_kv_name,
   fx_str_t* r_kv_cname,
   struct _fx_N14K_form__ktyp_t_data_t* r_kv_typ,
   struct _fx_R16Ast__val_flags_t* r_kv_flags,
   struct _fx_R10Ast__loc_t* r_kv_loc,
   struct _fx_R17K_form__kdefval_t* fx_result)
{
   fx_result->kv_name = *r_kv_name;
   fx_copy_str(r_kv_cname, &fx_result->kv_cname);
   FX_COPY_PTR(r_kv_typ, &fx_result->kv_typ);
   _fx_copy_R16Ast__val_flags_t(r_kv_flags, &fx_result->kv_flags);
   fx_result->kv_loc = *r_kv_loc;
}

static void _fx_free_T2R9Ast__id_tN14K_form__ktyp_t(struct _fx_T2R9Ast__id_tN14K_form__ktyp_t* dst)
{
   _fx_free_N14K_form__ktyp_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_T2R9Ast__id_tN14K_form__ktyp_t* src,
   struct _fx_T2R9Ast__id_tN14K_form__ktyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14K_form__ktyp_t_data_t* t1,
   struct _fx_T2R9Ast__id_tN14K_form__ktyp_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2R9Ast__id_tN14K_form__ktyp_t, _fx_free_T2R9Ast__id_tN14K_form__ktyp_t);
}

static int _fx_cons_LT2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_T2R9Ast__id_tN14K_form__ktyp_t* hd,
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2R9Ast__id_tN14K_form__ktyp_t, _fx_copy_T2R9Ast__id_tN14K_form__ktyp_t);
}

static void _fx_free_R23K_form__kdefinterface_t(struct _fx_R23K_form__kdefinterface_t* dst)
{
   fx_free_str(&dst->ki_cname);
   _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&dst->ki_all_methods);
   fx_free_list_simple(&dst->ki_scope);
}

static void _fx_copy_R23K_form__kdefinterface_t(
   struct _fx_R23K_form__kdefinterface_t* src,
   struct _fx_R23K_form__kdefinterface_t* dst)
{
   dst->ki_name = src->ki_name;
   dst->ki_base = src->ki_base;
   fx_copy_str(&src->ki_cname, &dst->ki_cname);
   dst->ki_id = src->ki_id;
   FX_COPY_PTR(src->ki_all_methods, &dst->ki_all_methods);
   FX_COPY_PTR(src->ki_scope, &dst->ki_scope);
   dst->ki_loc = src->ki_loc;
}

static void _fx_make_R23K_form__kdefinterface_t(
   struct _fx_R9Ast__id_t* r_ki_name,
   struct _fx_R9Ast__id_t* r_ki_base,
   fx_str_t* r_ki_cname,
   struct _fx_R9Ast__id_t* r_ki_id,
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* r_ki_all_methods,
   struct _fx_LN12Ast__scope_t_data_t* r_ki_scope,
   struct _fx_R10Ast__loc_t* r_ki_loc,
   struct _fx_R23K_form__kdefinterface_t* fx_result)
{
   fx_result->ki_name = *r_ki_name;
   fx_result->ki_base = *r_ki_base;
   fx_copy_str(r_ki_cname, &fx_result->ki_cname);
   fx_result->ki_id = *r_ki_id;
   FX_COPY_PTR(r_ki_all_methods, &fx_result->ki_all_methods);
   FX_COPY_PTR(r_ki_scope, &fx_result->ki_scope);
   fx_result->ki_loc = *r_ki_loc;
}

static void _fx_free_rR23K_form__kdefinterface_t(struct _fx_rR23K_form__kdefinterface_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR23K_form__kdefinterface_t, _fx_free_R23K_form__kdefinterface_t);
}

static int _fx_make_rR23K_form__kdefinterface_t(
   struct _fx_R23K_form__kdefinterface_t* arg,
   struct _fx_rR23K_form__kdefinterface_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR23K_form__kdefinterface_t, _fx_copy_R23K_form__kdefinterface_t);
}

static void _fx_free_R17K_form__kdeffun_t(struct _fx_R17K_form__kdeffun_t* dst)
{
   fx_free_str(&dst->kf_cname);
   fx_free_list_simple(&dst->kf_params);
   _fx_free_N14K_form__ktyp_t(&dst->kf_rt);
   _fx_free_N14K_form__kexp_t(&dst->kf_body);
   fx_free_list_simple(&dst->kf_scope);
}

static void _fx_copy_R17K_form__kdeffun_t(struct _fx_R17K_form__kdeffun_t* src, struct _fx_R17K_form__kdeffun_t* dst)
{
   dst->kf_name = src->kf_name;
   fx_copy_str(&src->kf_cname, &dst->kf_cname);
   FX_COPY_PTR(src->kf_params, &dst->kf_params);
   FX_COPY_PTR(src->kf_rt, &dst->kf_rt);
   FX_COPY_PTR(src->kf_body, &dst->kf_body);
   dst->kf_flags = src->kf_flags;
   dst->kf_closure = src->kf_closure;
   FX_COPY_PTR(src->kf_scope, &dst->kf_scope);
   dst->kf_loc = src->kf_loc;
}

static void _fx_make_R17K_form__kdeffun_t(
   struct _fx_R9Ast__id_t* r_kf_name,
   fx_str_t* r_kf_cname,
   struct _fx_LR9Ast__id_t_data_t* r_kf_params,
   struct _fx_N14K_form__ktyp_t_data_t* r_kf_rt,
   struct _fx_N14K_form__kexp_t_data_t* r_kf_body,
   struct _fx_R16Ast__fun_flags_t* r_kf_flags,
   struct _fx_R25K_form__kdefclosureinfo_t* r_kf_closure,
   struct _fx_LN12Ast__scope_t_data_t* r_kf_scope,
   struct _fx_R10Ast__loc_t* r_kf_loc,
   struct _fx_R17K_form__kdeffun_t* fx_result)
{
   fx_result->kf_name = *r_kf_name;
   fx_copy_str(r_kf_cname, &fx_result->kf_cname);
   FX_COPY_PTR(r_kf_params, &fx_result->kf_params);
   FX_COPY_PTR(r_kf_rt, &fx_result->kf_rt);
   FX_COPY_PTR(r_kf_body, &fx_result->kf_body);
   fx_result->kf_flags = *r_kf_flags;
   fx_result->kf_closure = *r_kf_closure;
   FX_COPY_PTR(r_kf_scope, &fx_result->kf_scope);
   fx_result->kf_loc = *r_kf_loc;
}

static void _fx_free_rR17K_form__kdeffun_t(struct _fx_rR17K_form__kdeffun_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR17K_form__kdeffun_t, _fx_free_R17K_form__kdeffun_t);
}

static int _fx_make_rR17K_form__kdeffun_t(
   struct _fx_R17K_form__kdeffun_t* arg,
   struct _fx_rR17K_form__kdeffun_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR17K_form__kdeffun_t, _fx_copy_R17K_form__kdeffun_t);
}

static void _fx_free_R17K_form__kdefexn_t(struct _fx_R17K_form__kdefexn_t* dst)
{
   fx_free_str(&dst->ke_cname);
   fx_free_str(&dst->ke_base_cname);
   _fx_free_N14K_form__ktyp_t(&dst->ke_typ);
   fx_free_list_simple(&dst->ke_scope);
}

static void _fx_copy_R17K_form__kdefexn_t(struct _fx_R17K_form__kdefexn_t* src, struct _fx_R17K_form__kdefexn_t* dst)
{
   dst->ke_name = src->ke_name;
   fx_copy_str(&src->ke_cname, &dst->ke_cname);
   fx_copy_str(&src->ke_base_cname, &dst->ke_base_cname);
   FX_COPY_PTR(src->ke_typ, &dst->ke_typ);
   dst->ke_std = src->ke_std;
   dst->ke_tag = src->ke_tag;
   dst->ke_make = src->ke_make;
   FX_COPY_PTR(src->ke_scope, &dst->ke_scope);
   dst->ke_loc = src->ke_loc;
}

static void _fx_make_R17K_form__kdefexn_t(
   struct _fx_R9Ast__id_t* r_ke_name,
   fx_str_t* r_ke_cname,
   fx_str_t* r_ke_base_cname,
   struct _fx_N14K_form__ktyp_t_data_t* r_ke_typ,
   bool r_ke_std,
   struct _fx_R9Ast__id_t* r_ke_tag,
   struct _fx_R9Ast__id_t* r_ke_make,
   struct _fx_LN12Ast__scope_t_data_t* r_ke_scope,
   struct _fx_R10Ast__loc_t* r_ke_loc,
   struct _fx_R17K_form__kdefexn_t* fx_result)
{
   fx_result->ke_name = *r_ke_name;
   fx_copy_str(r_ke_cname, &fx_result->ke_cname);
   fx_copy_str(r_ke_base_cname, &fx_result->ke_base_cname);
   FX_COPY_PTR(r_ke_typ, &fx_result->ke_typ);
   fx_result->ke_std = r_ke_std;
   fx_result->ke_tag = *r_ke_tag;
   fx_result->ke_make = *r_ke_make;
   FX_COPY_PTR(r_ke_scope, &fx_result->ke_scope);
   fx_result->ke_loc = *r_ke_loc;
}

static void _fx_free_rR17K_form__kdefexn_t(struct _fx_rR17K_form__kdefexn_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR17K_form__kdefexn_t, _fx_free_R17K_form__kdefexn_t);
}

static int _fx_make_rR17K_form__kdefexn_t(
   struct _fx_R17K_form__kdefexn_t* arg,
   struct _fx_rR17K_form__kdefexn_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR17K_form__kdefexn_t, _fx_copy_R17K_form__kdefexn_t);
}

static void _fx_free_LN14K_form__ktyp_t(struct _fx_LN14K_form__ktyp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN14K_form__ktyp_t, _fx_free_N14K_form__ktyp_t);
}

static int _fx_cons_LN14K_form__ktyp_t(
   struct _fx_N14K_form__ktyp_t_data_t* hd,
   struct _fx_LN14K_form__ktyp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN14K_form__ktyp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN14K_form__ktyp_t, FX_COPY_PTR);
}

static void _fx_free_T2R9Ast__id_tLR9Ast__id_t(struct _fx_T2R9Ast__id_tLR9Ast__id_t* dst)
{
   fx_free_list_simple(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tLR9Ast__id_t(
   struct _fx_T2R9Ast__id_tLR9Ast__id_t* src,
   struct _fx_T2R9Ast__id_tLR9Ast__id_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tLR9Ast__id_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_LR9Ast__id_t_data_t* t1,
   struct _fx_T2R9Ast__id_tLR9Ast__id_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LT2R9Ast__id_tLR9Ast__id_t(struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2R9Ast__id_tLR9Ast__id_t, _fx_free_T2R9Ast__id_tLR9Ast__id_t);
}

static int _fx_cons_LT2R9Ast__id_tLR9Ast__id_t(
   struct _fx_T2R9Ast__id_tLR9Ast__id_t* hd,
   struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2R9Ast__id_tLR9Ast__id_t, _fx_copy_T2R9Ast__id_tLR9Ast__id_t);
}

static void _fx_free_R21K_form__kdefvariant_t(struct _fx_R21K_form__kdefvariant_t* dst)
{
   fx_free_str(&dst->kvar_cname);
   _fx_free_LN14K_form__ktyp_t(&dst->kvar_targs);
   _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&dst->kvar_cases);
   fx_free_list_simple(&dst->kvar_ctors);
   _fx_free_LT2R9Ast__id_tLR9Ast__id_t(&dst->kvar_ifaces);
   fx_free_list_simple(&dst->kvar_scope);
}

static void _fx_copy_R21K_form__kdefvariant_t(
   struct _fx_R21K_form__kdefvariant_t* src,
   struct _fx_R21K_form__kdefvariant_t* dst)
{
   dst->kvar_name = src->kvar_name;
   fx_copy_str(&src->kvar_cname, &dst->kvar_cname);
   dst->kvar_proto = src->kvar_proto;
   dst->kvar_props = src->kvar_props;
   FX_COPY_PTR(src->kvar_targs, &dst->kvar_targs);
   FX_COPY_PTR(src->kvar_cases, &dst->kvar_cases);
   FX_COPY_PTR(src->kvar_ctors, &dst->kvar_ctors);
   dst->kvar_flags = src->kvar_flags;
   FX_COPY_PTR(src->kvar_ifaces, &dst->kvar_ifaces);
   FX_COPY_PTR(src->kvar_scope, &dst->kvar_scope);
   dst->kvar_loc = src->kvar_loc;
}

static void _fx_make_R21K_form__kdefvariant_t(
   struct _fx_R9Ast__id_t* r_kvar_name,
   fx_str_t* r_kvar_cname,
   struct _fx_R9Ast__id_t* r_kvar_proto,
   struct _fx_Nt6option1R17K_form__ktprops_t* r_kvar_props,
   struct _fx_LN14K_form__ktyp_t_data_t* r_kvar_targs,
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* r_kvar_cases,
   struct _fx_LR9Ast__id_t_data_t* r_kvar_ctors,
   struct _fx_R16Ast__var_flags_t* r_kvar_flags,
   struct _fx_LT2R9Ast__id_tLR9Ast__id_t_data_t* r_kvar_ifaces,
   struct _fx_LN12Ast__scope_t_data_t* r_kvar_scope,
   struct _fx_R10Ast__loc_t* r_kvar_loc,
   struct _fx_R21K_form__kdefvariant_t* fx_result)
{
   fx_result->kvar_name = *r_kvar_name;
   fx_copy_str(r_kvar_cname, &fx_result->kvar_cname);
   fx_result->kvar_proto = *r_kvar_proto;
   fx_result->kvar_props = *r_kvar_props;
   FX_COPY_PTR(r_kvar_targs, &fx_result->kvar_targs);
   FX_COPY_PTR(r_kvar_cases, &fx_result->kvar_cases);
   FX_COPY_PTR(r_kvar_ctors, &fx_result->kvar_ctors);
   fx_result->kvar_flags = *r_kvar_flags;
   FX_COPY_PTR(r_kvar_ifaces, &fx_result->kvar_ifaces);
   FX_COPY_PTR(r_kvar_scope, &fx_result->kvar_scope);
   fx_result->kvar_loc = *r_kvar_loc;
}

static void _fx_free_rR21K_form__kdefvariant_t(struct _fx_rR21K_form__kdefvariant_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR21K_form__kdefvariant_t, _fx_free_R21K_form__kdefvariant_t);
}

static int _fx_make_rR21K_form__kdefvariant_t(
   struct _fx_R21K_form__kdefvariant_t* arg,
   struct _fx_rR21K_form__kdefvariant_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR21K_form__kdefvariant_t, _fx_copy_R21K_form__kdefvariant_t);
}

static void _fx_free_R17K_form__kdeftyp_t(struct _fx_R17K_form__kdeftyp_t* dst)
{
   fx_free_str(&dst->kt_cname);
   _fx_free_LN14K_form__ktyp_t(&dst->kt_targs);
   _fx_free_N14K_form__ktyp_t(&dst->kt_typ);
   fx_free_list_simple(&dst->kt_scope);
}

static void _fx_copy_R17K_form__kdeftyp_t(struct _fx_R17K_form__kdeftyp_t* src, struct _fx_R17K_form__kdeftyp_t* dst)
{
   dst->kt_name = src->kt_name;
   fx_copy_str(&src->kt_cname, &dst->kt_cname);
   dst->kt_proto = src->kt_proto;
   dst->kt_props = src->kt_props;
   FX_COPY_PTR(src->kt_targs, &dst->kt_targs);
   FX_COPY_PTR(src->kt_typ, &dst->kt_typ);
   FX_COPY_PTR(src->kt_scope, &dst->kt_scope);
   dst->kt_loc = src->kt_loc;
}

static void _fx_make_R17K_form__kdeftyp_t(
   struct _fx_R9Ast__id_t* r_kt_name,
   fx_str_t* r_kt_cname,
   struct _fx_R9Ast__id_t* r_kt_proto,
   struct _fx_Nt6option1R17K_form__ktprops_t* r_kt_props,
   struct _fx_LN14K_form__ktyp_t_data_t* r_kt_targs,
   struct _fx_N14K_form__ktyp_t_data_t* r_kt_typ,
   struct _fx_LN12Ast__scope_t_data_t* r_kt_scope,
   struct _fx_R10Ast__loc_t* r_kt_loc,
   struct _fx_R17K_form__kdeftyp_t* fx_result)
{
   fx_result->kt_name = *r_kt_name;
   fx_copy_str(r_kt_cname, &fx_result->kt_cname);
   fx_result->kt_proto = *r_kt_proto;
   fx_result->kt_props = *r_kt_props;
   FX_COPY_PTR(r_kt_targs, &fx_result->kt_targs);
   FX_COPY_PTR(r_kt_typ, &fx_result->kt_typ);
   FX_COPY_PTR(r_kt_scope, &fx_result->kt_scope);
   fx_result->kt_loc = *r_kt_loc;
}

static void _fx_free_rR17K_form__kdeftyp_t(struct _fx_rR17K_form__kdeftyp_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR17K_form__kdeftyp_t, _fx_free_R17K_form__kdeftyp_t);
}

static int _fx_make_rR17K_form__kdeftyp_t(
   struct _fx_R17K_form__kdeftyp_t* arg,
   struct _fx_rR17K_form__kdeftyp_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR17K_form__kdeftyp_t, _fx_copy_R17K_form__kdeftyp_t);
}

static void _fx_free_R25K_form__kdefclosurevars_t(struct _fx_R25K_form__kdefclosurevars_t* dst)
{
   fx_free_str(&dst->kcv_cname);
   _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&dst->kcv_freevars);
   fx_free_list_simple(&dst->kcv_orig_freevars);
   fx_free_list_simple(&dst->kcv_scope);
}

static void _fx_copy_R25K_form__kdefclosurevars_t(
   struct _fx_R25K_form__kdefclosurevars_t* src,
   struct _fx_R25K_form__kdefclosurevars_t* dst)
{
   dst->kcv_name = src->kcv_name;
   fx_copy_str(&src->kcv_cname, &dst->kcv_cname);
   FX_COPY_PTR(src->kcv_freevars, &dst->kcv_freevars);
   FX_COPY_PTR(src->kcv_orig_freevars, &dst->kcv_orig_freevars);
   FX_COPY_PTR(src->kcv_scope, &dst->kcv_scope);
   dst->kcv_loc = src->kcv_loc;
}

static void _fx_make_R25K_form__kdefclosurevars_t(
   struct _fx_R9Ast__id_t* r_kcv_name,
   fx_str_t* r_kcv_cname,
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* r_kcv_freevars,
   struct _fx_LR9Ast__id_t_data_t* r_kcv_orig_freevars,
   struct _fx_LN12Ast__scope_t_data_t* r_kcv_scope,
   struct _fx_R10Ast__loc_t* r_kcv_loc,
   struct _fx_R25K_form__kdefclosurevars_t* fx_result)
{
   fx_result->kcv_name = *r_kcv_name;
   fx_copy_str(r_kcv_cname, &fx_result->kcv_cname);
   FX_COPY_PTR(r_kcv_freevars, &fx_result->kcv_freevars);
   FX_COPY_PTR(r_kcv_orig_freevars, &fx_result->kcv_orig_freevars);
   FX_COPY_PTR(r_kcv_scope, &fx_result->kcv_scope);
   fx_result->kcv_loc = *r_kcv_loc;
}

static void _fx_free_rR25K_form__kdefclosurevars_t(struct _fx_rR25K_form__kdefclosurevars_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR25K_form__kdefclosurevars_t, _fx_free_R25K_form__kdefclosurevars_t);
}

static int _fx_make_rR25K_form__kdefclosurevars_t(
   struct _fx_R25K_form__kdefclosurevars_t* arg,
   struct _fx_rR25K_form__kdefclosurevars_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR25K_form__kdefclosurevars_t, _fx_copy_R25K_form__kdefclosurevars_t);
}

static void _fx_free_N15K_form__kinfo_t(struct _fx_N15K_form__kinfo_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_R17K_form__kdefval_t(&dst->u.KVal); break;
   case 3:
      _fx_free_rR17K_form__kdeffun_t(&dst->u.KFun); break;
   case 4:
      _fx_free_rR17K_form__kdefexn_t(&dst->u.KExn); break;
   case 5:
      _fx_free_rR21K_form__kdefvariant_t(&dst->u.KVariant); break;
   case 6:
      _fx_free_rR25K_form__kdefclosurevars_t(&dst->u.KClosureVars); break;
   case 7:
      _fx_free_rR23K_form__kdefinterface_t(&dst->u.KInterface); break;
   case 8:
      _fx_free_rR17K_form__kdeftyp_t(&dst->u.KTyp); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_N15K_form__kinfo_t(struct _fx_N15K_form__kinfo_t* src, struct _fx_N15K_form__kinfo_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      _fx_copy_R17K_form__kdefval_t(&src->u.KVal, &dst->u.KVal); break;
   case 3:
      FX_COPY_PTR(src->u.KFun, &dst->u.KFun); break;
   case 4:
      FX_COPY_PTR(src->u.KExn, &dst->u.KExn); break;
   case 5:
      FX_COPY_PTR(src->u.KVariant, &dst->u.KVariant); break;
   case 6:
      FX_COPY_PTR(src->u.KClosureVars, &dst->u.KClosureVars); break;
   case 7:
      FX_COPY_PTR(src->u.KInterface, &dst->u.KInterface); break;
   case 8:
      FX_COPY_PTR(src->u.KTyp, &dst->u.KTyp); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t(
   struct _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t* dst)
{
   fx_free_arr(&dst->t4);
   fx_free_arr(&dst->t5);
}

static void _fx_copy_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t(
   struct _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t* src,
   struct _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   dst->t2 = src->t2;
   dst->t3 = src->t3;
   fx_copy_arr(&src->t4, &dst->t4);
   fx_copy_arr(&src->t5, &dst->t5);
}

static void _fx_make_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t(
   struct _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t* t0,
   int_ t1,
   int_ t2,
   int_ t3,
   fx_arr_t* t4,
   fx_arr_t* t5,
   struct _fx_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t* fx_result)
{
   fx_result->t0 = *t0;
   fx_result->t1 = t1;
   fx_result->t2 = t2;
   fx_result->t3 = t3;
   fx_copy_arr(t4, &fx_result->t4);
   fx_copy_arr(t5, &fx_result->t5);
}

static void _fx_free_Nt10Hashset__t1R9Ast__id_t(struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      _fx_free_T6Rt24Hashset__hashset_entry_t1R9Ast__id_tiiiA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_t(&(*dst)->u.t);
      fx_free(*dst);
   }
   *dst = 0;
}

static void
   _fx_free_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t(
   struct _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t*
      dst)
{
   _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&dst->t1);
   _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&dst->t4);
}

static void
   _fx_copy_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t(
   struct _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t*
      src,
   struct _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t*
      dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
   dst->t3 = src->t3;
   FX_COPY_PTR(src->t4, &dst->t4);
}

static void
   _fx_make_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t(
   struct _fx_N12Map__color_t* t0,
   struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t* t1,
   struct _fx_R9Ast__id_t* t2,
   struct _fx_R9Ast__id_t* t3,
   struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t* t4,
   struct _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t*
      fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
   fx_result->t3 = *t3;
   FX_COPY_PTR(t4, &fx_result->t4);
}

static void _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      _fx_free_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t(
         &(*dst)->u.Node);
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_Rt6Map__t2R9Ast__id_tR9Ast__id_t(struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t* dst)
{
   _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&dst->root);
   fx_free_fp(&dst->cmp);
}

static void _fx_copy_Rt6Map__t2R9Ast__id_tR9Ast__id_t(
   struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t* src,
   struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t* dst)
{
   FX_COPY_PTR(src->root, &dst->root);
   FX_COPY_FP(&src->cmp, &dst->cmp);
}

static void _fx_make_Rt6Map__t2R9Ast__id_tR9Ast__id_t(
   struct _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t_data_t* r_root,
   struct _fx_FPi2R9Ast__id_tR9Ast__id_t* r_cmp,
   struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t* fx_result)
{
   FX_COPY_PTR(r_root, &fx_result->root);
   FX_COPY_FP(r_cmp, &fx_result->cmp);
}

static void _fx_free_T2R10Ast__loc_tS(struct _fx_T2R10Ast__loc_tS* dst)
{
   fx_free_str(&dst->t1);
}

static void _fx_copy_T2R10Ast__loc_tS(struct _fx_T2R10Ast__loc_tS* src, struct _fx_T2R10Ast__loc_tS* dst)
{
   dst->t0 = src->t0;
   fx_copy_str(&src->t1, &dst->t1);
}

static void _fx_make_T2R10Ast__loc_tS(struct _fx_R10Ast__loc_t* t0, fx_str_t* t1, struct _fx_T2R10Ast__loc_tS* fx_result)
{
   fx_result->t0 = *t0;
   fx_copy_str(t1, &fx_result->t1);
}

static void _fx_free_N13Ast__binary_t(struct _fx_N13Ast__binary_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      switch ((*dst)->tag) {
      case 27:
         _fx_free_N13Ast__binary_t(&(*dst)->u.OpAugBinary); break;
      default:
         ;
      }
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_T2SR10Ast__loc_t(struct _fx_T2SR10Ast__loc_t* dst)
{
   fx_free_str(&dst->t0);
}

static void _fx_copy_T2SR10Ast__loc_t(struct _fx_T2SR10Ast__loc_t* src, struct _fx_T2SR10Ast__loc_t* dst)
{
   fx_copy_str(&src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2SR10Ast__loc_t(fx_str_t* t0, struct _fx_R10Ast__loc_t* t1, struct _fx_T2SR10Ast__loc_t* fx_result)
{
   fx_copy_str(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_LT2SR10Ast__loc_t(struct _fx_LT2SR10Ast__loc_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2SR10Ast__loc_t, _fx_free_T2SR10Ast__loc_t);
}

static int _fx_cons_LT2SR10Ast__loc_t(
   struct _fx_T2SR10Ast__loc_t* hd,
   struct _fx_LT2SR10Ast__loc_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2SR10Ast__loc_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2SR10Ast__loc_t, _fx_copy_T2SR10Ast__loc_t);
}

static int _fx_cons_Li(int_ hd, struct _fx_Li_data_t* tl, bool addref_tl, struct _fx_Li_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_Li, FX_COPY_SIMPLE);
}

static int _fx_make_rB(bool arg, struct _fx_rB_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rB, FX_COPY_SIMPLE);
}

static int _fx_make_ri(int_ arg, struct _fx_ri_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_ri, FX_COPY_SIMPLE);
}

static void _fx_free_N14K_form__klit_t(struct _fx_N14K_form__klit_t* dst)
{
   switch (dst->tag) {
   case 5:
      fx_free_str(&dst->u.KLitString); break;
   case 8:
      _fx_free_N14K_form__ktyp_t(&dst->u.KLitNil); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_N14K_form__klit_t(struct _fx_N14K_form__klit_t* src, struct _fx_N14K_form__klit_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 5:
      fx_copy_str(&src->u.KLitString, &dst->u.KLitString); break;
   case 8:
      FX_COPY_PTR(src->u.KLitNil, &dst->u.KLitNil); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_N14K_form__atom_t(struct _fx_N14K_form__atom_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_N14K_form__klit_t(&dst->u.AtomLit); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_N14K_form__atom_t(struct _fx_N14K_form__atom_t* src, struct _fx_N14K_form__atom_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      _fx_copy_N14K_form__klit_t(&src->u.AtomLit, &dst->u.AtomLit); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_R22K_form__k_fold_callb_t(struct _fx_R22K_form__k_fold_callb_t* dst)
{
   _fx_free_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(&dst->kcb_fold_ktyp);
   _fx_free_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(&dst->kcb_fold_kexp);
   _fx_free_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(&dst->kcb_fold_atom);
}

static void _fx_copy_R22K_form__k_fold_callb_t(
   struct _fx_R22K_form__k_fold_callb_t* src,
   struct _fx_R22K_form__k_fold_callb_t* dst)
{
   FX_COPY_PTR(src->kcb_fold_ktyp, &dst->kcb_fold_ktyp);
   FX_COPY_PTR(src->kcb_fold_kexp, &dst->kcb_fold_kexp);
   FX_COPY_PTR(src->kcb_fold_atom, &dst->kcb_fold_atom);
}

static void _fx_make_R22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t* r_kcb_fold_ktyp,
   struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t* r_kcb_fold_kexp,
   struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t* r_kcb_fold_atom,
   struct _fx_R22K_form__k_fold_callb_t* fx_result)
{
   FX_COPY_PTR(r_kcb_fold_ktyp, &fx_result->kcb_fold_ktyp);
   FX_COPY_PTR(r_kcb_fold_kexp, &fx_result->kcb_fold_kexp);
   FX_COPY_PTR(r_kcb_fold_atom, &fx_result->kcb_fold_atom);
}

static void _fx_free_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      fx_free_fp(&(*dst)->u.Some); fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      fx_free_fp(&(*dst)->u.Some); fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      fx_free_fp(&(*dst)->u.Some); fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_Nt6option1N14K_form__atom_t(struct _fx_Nt6option1N14K_form__atom_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_N14K_form__atom_t(&dst->u.Some); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_Nt6option1N14K_form__atom_t(
   struct _fx_Nt6option1N14K_form__atom_t* src,
   struct _fx_Nt6option1N14K_form__atom_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      _fx_copy_N14K_form__atom_t(&src->u.Some, &dst->u.Some); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_LN14K_form__kexp_t(struct _fx_LN14K_form__kexp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN14K_form__kexp_t, _fx_free_N14K_form__kexp_t);
}

static int _fx_cons_LN14K_form__kexp_t(
   struct _fx_N14K_form__kexp_t_data_t* hd,
   struct _fx_LN14K_form__kexp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN14K_form__kexp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN14K_form__kexp_t, FX_COPY_PTR);
}

static void _fx_free_T2BN14K_form__atom_t(struct _fx_T2BN14K_form__atom_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t1);
}

static void _fx_copy_T2BN14K_form__atom_t(struct _fx_T2BN14K_form__atom_t* src, struct _fx_T2BN14K_form__atom_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_N14K_form__atom_t(&src->t1, &dst->t1);
}

static void _fx_make_T2BN14K_form__atom_t(bool t0, struct _fx_N14K_form__atom_t* t1, struct _fx_T2BN14K_form__atom_t* fx_result)
{
   fx_result->t0 = t0;
   _fx_copy_N14K_form__atom_t(t1, &fx_result->t1);
}

static void _fx_free_LT2BN14K_form__atom_t(struct _fx_LT2BN14K_form__atom_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2BN14K_form__atom_t, _fx_free_T2BN14K_form__atom_t);
}

static int _fx_cons_LT2BN14K_form__atom_t(
   struct _fx_T2BN14K_form__atom_t* hd,
   struct _fx_LT2BN14K_form__atom_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2BN14K_form__atom_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2BN14K_form__atom_t, _fx_copy_T2BN14K_form__atom_t);
}

static void _fx_free_R14Ast__pragmas_t(struct _fx_R14Ast__pragmas_t* dst)
{
   _fx_free_LT2SR10Ast__loc_t(&dst->pragma_clibs);
}

static void _fx_copy_R14Ast__pragmas_t(struct _fx_R14Ast__pragmas_t* src, struct _fx_R14Ast__pragmas_t* dst)
{
   dst->pragma_cpp = src->pragma_cpp;
   FX_COPY_PTR(src->pragma_clibs, &dst->pragma_clibs);
}

static void _fx_make_R14Ast__pragmas_t(
   bool r_pragma_cpp,
   struct _fx_LT2SR10Ast__loc_t_data_t* r_pragma_clibs,
   struct _fx_R14Ast__pragmas_t* fx_result)
{
   fx_result->pragma_cpp = r_pragma_cpp;
   FX_COPY_PTR(r_pragma_clibs, &fx_result->pragma_clibs);
}

static void _fx_free_T2LN14K_form__ktyp_tN14K_form__ktyp_t(struct _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t* dst)
{
   _fx_free_LN14K_form__ktyp_t(&dst->t0);
   _fx_free_N14K_form__ktyp_t(&dst->t1);
}

static void _fx_copy_T2LN14K_form__ktyp_tN14K_form__ktyp_t(
   struct _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t* src,
   struct _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LN14K_form__ktyp_tN14K_form__ktyp_t(
   struct _fx_LN14K_form__ktyp_t_data_t* t0,
   struct _fx_N14K_form__ktyp_t_data_t* t1,
   struct _fx_T2LN14K_form__ktyp_tN14K_form__ktyp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t(struct _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t* dst)
{
   _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t* src,
   struct _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* t1,
   struct _fx_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T2iN14K_form__ktyp_t(struct _fx_T2iN14K_form__ktyp_t* dst)
{
   _fx_free_N14K_form__ktyp_t(&dst->t1);
}

static void _fx_copy_T2iN14K_form__ktyp_t(struct _fx_T2iN14K_form__ktyp_t* src, struct _fx_T2iN14K_form__ktyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2iN14K_form__ktyp_t(
   int_ t0,
   struct _fx_N14K_form__ktyp_t_data_t* t1,
   struct _fx_T2iN14K_form__ktyp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_N14K_form__ktyp_t(struct _fx_N14K_form__ktyp_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      switch ((*dst)->tag) {
      case 12:
         _fx_free_N14K_form__ktyp_t(&(*dst)->u.KTypRawPointer); break;
      case 13:
         _fx_free_T2LN14K_form__ktyp_tN14K_form__ktyp_t(&(*dst)->u.KTypFun); break;
      case 14:
         _fx_free_LN14K_form__ktyp_t(&(*dst)->u.KTypTuple); break;
      case 15:
         _fx_free_T2R9Ast__id_tLT2R9Ast__id_tN14K_form__ktyp_t(&(*dst)->u.KTypRecord); break;
      case 17:
         _fx_free_T2iN14K_form__ktyp_t(&(*dst)->u.KTypArray); break;
      case 18:
         _fx_free_N14K_form__ktyp_t(&(*dst)->u.KTypVector); break;
      case 19:
         _fx_free_N14K_form__ktyp_t(&(*dst)->u.KTypList); break;
      case 20:
         _fx_free_N14K_form__ktyp_t(&(*dst)->u.KTypRef); break;
      default:
         ;
      }
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_Ta3N14K_form__atom_t(struct _fx_Ta3N14K_form__atom_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t0);
   _fx_free_N14K_form__atom_t(&dst->t1);
   _fx_free_N14K_form__atom_t(&dst->t2);
}

static void _fx_copy_Ta3N14K_form__atom_t(struct _fx_Ta3N14K_form__atom_t* src, struct _fx_Ta3N14K_form__atom_t* dst)
{
   _fx_copy_N14K_form__atom_t(&src->t0, &dst->t0);
   _fx_copy_N14K_form__atom_t(&src->t1, &dst->t1);
   _fx_copy_N14K_form__atom_t(&src->t2, &dst->t2);
}

static void _fx_make_Ta3N14K_form__atom_t(
   struct _fx_N14K_form__atom_t* t0,
   struct _fx_N14K_form__atom_t* t1,
   struct _fx_N14K_form__atom_t* t2,
   struct _fx_Ta3N14K_form__atom_t* fx_result)
{
   _fx_copy_N14K_form__atom_t(t0, &fx_result->t0);
   _fx_copy_N14K_form__atom_t(t1, &fx_result->t1);
   _fx_copy_N14K_form__atom_t(t2, &fx_result->t2);
}

static void _fx_free_N13K_form__dom_t(struct _fx_N13K_form__dom_t* dst)
{
   switch (dst->tag) {
   case 1:
      _fx_free_N14K_form__atom_t(&dst->u.DomainElem); break;
   case 2:
      _fx_free_N14K_form__atom_t(&dst->u.DomainFast); break;
   case 3:
      _fx_free_Ta3N14K_form__atom_t(&dst->u.DomainRange); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_N13K_form__dom_t(struct _fx_N13K_form__dom_t* src, struct _fx_N13K_form__dom_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 1:
      _fx_copy_N14K_form__atom_t(&src->u.DomainElem, &dst->u.DomainElem); break;
   case 2:
      _fx_copy_N14K_form__atom_t(&src->u.DomainFast, &dst->u.DomainFast); break;
   case 3:
      _fx_copy_Ta3N14K_form__atom_t(&src->u.DomainRange, &dst->u.DomainRange); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_T2Nt6option1N14K_form__atom_tR10Ast__loc_t(struct _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t* dst)
{
   _fx_free_Nt6option1N14K_form__atom_t(&dst->t0);
}

static void _fx_copy_T2Nt6option1N14K_form__atom_tR10Ast__loc_t(
   struct _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t* src,
   struct _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t* dst)
{
   _fx_copy_Nt6option1N14K_form__atom_t(&src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2Nt6option1N14K_form__atom_tR10Ast__loc_t(
   struct _fx_Nt6option1N14K_form__atom_t* t0,
   struct _fx_R10Ast__loc_t* t1,
   struct _fx_T2Nt6option1N14K_form__atom_tR10Ast__loc_t* fx_result)
{
   _fx_copy_Nt6option1N14K_form__atom_t(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__ktyp_t(&dst->t0);
}

static void _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__ktyp_t_data_t* t0,
   struct _fx_R10Ast__loc_t* t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_copy_N14K_form__atom_t(&src->t0, &dst->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* t0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t1,
   struct _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   _fx_copy_N14K_form__atom_t(t0, &fx_result->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N13Ast__binary_t(&dst->t0);
   _fx_free_N14K_form__atom_t(&dst->t1);
   _fx_free_N14K_form__atom_t(&dst->t2);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t3);
}

static void _fx_copy_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   _fx_copy_N14K_form__atom_t(&src->t1, &dst->t1);
   _fx_copy_N14K_form__atom_t(&src->t2, &dst->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void _fx_make_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N13Ast__binary_t_data_t* t0,
   struct _fx_N14K_form__atom_t* t1,
   struct _fx_N14K_form__atom_t* t2,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t3,
   struct _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   _fx_copy_N14K_form__atom_t(t1, &fx_result->t1);
   _fx_copy_N14K_form__atom_t(t2, &fx_result->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t1);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_N14K_form__atom_t(&src->t1, &dst->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N12Ast__unary_t* t0,
   struct _fx_N14K_form__atom_t* t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t2,
   struct _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   _fx_copy_N14K_form__atom_t(t1, &fx_result->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_LN14K_form__atom_t(struct _fx_LN14K_form__atom_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN14K_form__atom_t, _fx_free_N14K_form__atom_t);
}

static int _fx_cons_LN14K_form__atom_t(
   struct _fx_N14K_form__atom_t* hd,
   struct _fx_LN14K_form__atom_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN14K_form__atom_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN14K_form__atom_t, _fx_copy_N14K_form__atom_t);
}

static void _fx_free_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14K_form__atom_t(&dst->t1);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N13Ast__intrin_t* t0,
   struct _fx_LN14K_form__atom_t_data_t* t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t2,
   struct _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T2R9Ast__id_tN14K_form__kexp_t(struct _fx_T2R9Ast__id_tN14K_form__kexp_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tN14K_form__kexp_t(
   struct _fx_T2R9Ast__id_tN14K_form__kexp_t* src,
   struct _fx_T2R9Ast__id_tN14K_form__kexp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tN14K_form__kexp_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_T2R9Ast__id_tN14K_form__kexp_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14K_form__kexp_t(&dst->t0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_LN14K_form__kexp_t_data_t* t0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t1,
   struct _fx_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t0);
   _fx_free_N14K_form__kexp_t(&dst->t1);
   _fx_free_N14K_form__kexp_t(&dst->t2);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t3);
}

static void _fx_copy_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void _fx_make_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__kexp_t_data_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_N14K_form__kexp_t_data_t* t2,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t3,
   struct _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14K_form__atom_t(&dst->t1);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_LN14K_form__atom_t_data_t* t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t2,
   struct _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14K_form__atom_t(&dst->t2);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t3);
}

static void _fx_copy_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   FX_COPY_PTR(src->t2, &dst->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void _fx_make_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   int_ t1,
   struct _fx_LN14K_form__atom_t_data_t* t2,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t3,
   struct _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   fx_result->t1 = t1;
   FX_COPY_PTR(t2, &fx_result->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14K_form__atom_t(&dst->t0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_LN14K_form__atom_t_data_t* t0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t1,
   struct _fx_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14K_form__atom_t(&dst->t2);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t3);
}

static void _fx_copy_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   FX_COPY_PTR(src->t2, &dst->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void _fx_make_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_R9Ast__id_t* t1,
   struct _fx_LN14K_form__atom_t_data_t* t2,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t3,
   struct _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   fx_result->t1 = *t1;
   FX_COPY_PTR(t2, &fx_result->t2);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_LLT2BN14K_form__atom_t(struct _fx_LLT2BN14K_form__atom_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LLT2BN14K_form__atom_t, _fx_free_LT2BN14K_form__atom_t);
}

static int _fx_cons_LLT2BN14K_form__atom_t(
   struct _fx_LT2BN14K_form__atom_t_data_t* hd,
   struct _fx_LLT2BN14K_form__atom_t_data_t* tl,
   bool addref_tl,
   struct _fx_LLT2BN14K_form__atom_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LLT2BN14K_form__atom_t, FX_COPY_PTR);
}

static void _fx_free_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LLT2BN14K_form__atom_t(&dst->t1);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   bool t0,
   struct _fx_LLT2BN14K_form__atom_t_data_t* t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t2,
   struct _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LT2BN14K_form__atom_t(&dst->t0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_LT2BN14K_form__atom_t_data_t* t0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t1,
   struct _fx_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_LN13K_form__dom_t(struct _fx_LN13K_form__dom_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN13K_form__dom_t, _fx_free_N13K_form__dom_t);
}

static int _fx_cons_LN13K_form__dom_t(
   struct _fx_N13K_form__dom_t* hd,
   struct _fx_LN13K_form__dom_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN13K_form__dom_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN13K_form__dom_t, _fx_copy_N13K_form__dom_t);
}

static void _fx_free_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t0);
   _fx_free_LN13K_form__dom_t(&dst->t3);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t4);
}

static void _fx_copy_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_copy_N14K_form__atom_t(&src->t0, &dst->t0);
   dst->t1 = src->t1;
   dst->t2 = src->t2;
   FX_COPY_PTR(src->t3, &dst->t3);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t4, &dst->t4);
}

static void _fx_make_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* t0,
   struct _fx_N13Ast__border_t* t1,
   struct _fx_N18Ast__interpolate_t* t2,
   struct _fx_LN13K_form__dom_t_data_t* t3,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t4,
   struct _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t*
      fx_result)
{
   _fx_copy_N14K_form__atom_t(t0, &fx_result->t0);
   fx_result->t1 = *t1;
   fx_result->t2 = *t2;
   FX_COPY_PTR(t3, &fx_result->t3);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t4, &fx_result->t4);
}

static void _fx_free_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   int_ t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t2,
   struct _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   fx_result->t1 = t1;
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t(struct _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t1);
}

static void _fx_copy_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t(
   struct _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t* src,
   struct _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_N14K_form__atom_t(&src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14K_form__atom_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   _fx_copy_N14K_form__atom_t(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T2LN14K_form__kexp_tN14K_form__kexp_t(struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t* dst)
{
   _fx_free_LN14K_form__kexp_t(&dst->t0);
   _fx_free_N14K_form__kexp_t(&dst->t1);
}

static void _fx_copy_T2LN14K_form__kexp_tN14K_form__kexp_t(
   struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t* src,
   struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LN14K_form__kexp_tN14K_form__kexp_t(
   struct _fx_LN14K_form__kexp_t_data_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LT2LN14K_form__kexp_tN14K_form__kexp_t(struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2LN14K_form__kexp_tN14K_form__kexp_t, _fx_free_T2LN14K_form__kexp_tN14K_form__kexp_t);
}

static int _fx_cons_LT2LN14K_form__kexp_tN14K_form__kexp_t(
   struct _fx_T2LN14K_form__kexp_tN14K_form__kexp_t* hd,
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2LN14K_form__kexp_tN14K_form__kexp_t, _fx_copy_T2LN14K_form__kexp_tN14K_form__kexp_t);
}

static void _fx_free_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_LT2LN14K_form__kexp_tN14K_form__kexp_t(&dst->t0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t* t0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t1,
   struct _fx_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t0);
   _fx_free_N14K_form__kexp_t(&dst->t1);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__kexp_t_data_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t2,
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__atom_t(&dst->t0);
   _fx_free_N14K_form__ktyp_t(&dst->t1);
}

static void _fx_copy_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t* dst)
{
   _fx_copy_N14K_form__atom_t(&src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* t0,
   struct _fx_N14K_form__ktyp_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   _fx_copy_N14K_form__atom_t(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T2R9Ast__id_tN13K_form__dom_t(struct _fx_T2R9Ast__id_tN13K_form__dom_t* dst)
{
   _fx_free_N13K_form__dom_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tN13K_form__dom_t(
   struct _fx_T2R9Ast__id_tN13K_form__dom_t* src,
   struct _fx_T2R9Ast__id_tN13K_form__dom_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_N13K_form__dom_t(&src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tN13K_form__dom_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N13K_form__dom_t* t1,
   struct _fx_T2R9Ast__id_tN13K_form__dom_t* fx_result)
{
   fx_result->t0 = *t0;
   _fx_copy_N13K_form__dom_t(t1, &fx_result->t1);
}

static void _fx_free_LT2R9Ast__id_tN13K_form__dom_t(struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2R9Ast__id_tN13K_form__dom_t, _fx_free_T2R9Ast__id_tN13K_form__dom_t);
}

static int _fx_cons_LT2R9Ast__id_tN13K_form__dom_t(
   struct _fx_T2R9Ast__id_tN13K_form__dom_t* hd,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2R9Ast__id_tN13K_form__dom_t, _fx_copy_T2R9Ast__id_tN13K_form__dom_t);
}

static void _fx_free_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t0);
   _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&dst->t1);
   fx_free_list_simple(&dst->t2);
}

static void _fx_copy_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* src,
   struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_N14K_form__kexp_t_data_t* t0,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t1,
   struct _fx_LR9Ast__id_t_data_t* t2,
   struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t,
      _fx_free_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t);
}

static int _fx_cons_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* hd,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t,
      _fx_copy_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t);
}

static void
   _fx_free_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t*
      dst)
{
   _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&dst->t0);
   _fx_free_N14K_form__kexp_t(&dst->t1);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t3);
}

static void
   _fx_copy_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t*
      src,
   struct _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t*
      dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void
   _fx_make_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_R16Ast__for_flags_t* t2,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t3,
   struct _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t*
      fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t(
   struct _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t* dst)
{
   _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&dst->t0);
   fx_free_list_simple(&dst->t1);
   _fx_free_N14K_form__kexp_t(&dst->t2);
}

static void _fx_copy_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t(
   struct _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t* src,
   struct _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   dst->t3 = src->t3;
   dst->t4 = src->t4;
}

static void _fx_make_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t(
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t0,
   struct _fx_LR9Ast__id_t_data_t* t1,
   struct _fx_N14K_form__kexp_t_data_t* t2,
   struct _fx_R16Ast__for_flags_t* t3,
   struct _fx_R10Ast__loc_t* t4,
   struct _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   fx_result->t3 = *t3;
   fx_result->t4 = *t4;
}

static void _fx_free_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t(
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t0);
   _fx_free_N14K_form__kexp_t(&dst->t1);
}

static void _fx_copy_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t(
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t* src,
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t(
   struct _fx_N14K_form__kexp_t_data_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T2ST2N14K_form__ktyp_tR10Ast__loc_t(struct _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   fx_free_str(&dst->t0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2ST2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t* src,
   struct _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t* dst)
{
   fx_copy_str(&src->t0, &dst->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2ST2N14K_form__ktyp_tR10Ast__loc_t(
   fx_str_t* t0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* t1,
   struct _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t* fx_result)
{
   fx_copy_str(t0, &fx_result->t0);
   _fx_copy_T2N14K_form__ktyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t(struct _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t1);
}

static void _fx_copy_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t(
   struct _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t* src,
   struct _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_N14K_form__kexp_t(struct _fx_N14K_form__kexp_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      switch ((*dst)->tag) {
      case 4:
         _fx_free_T2Nt6option1N14K_form__atom_tR10Ast__loc_t(&(*dst)->u.KExpReturn); break;
      case 5:
         _fx_free_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpAtom); break;
      case 6:
         _fx_free_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpBinary);
         break;
      case 7:
         _fx_free_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpUnary); break;
      case 8:
         _fx_free_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpIntrin); break;
      case 9:
         _fx_free_T2R9Ast__id_tN14K_form__kexp_t(&(*dst)->u.KExpSync); break;
      case 10:
         _fx_free_T2LN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpSeq); break;
      case 11:
         _fx_free_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpIf);
         break;
      case 12:
         _fx_free_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpCall); break;
      case 13:
         _fx_free_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpICall); break;
      case 14:
         _fx_free_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMkTuple); break;
      case 15:
         _fx_free_T2LN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMkRecord); break;
      case 16:
         _fx_free_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMkClosure); break;
      case 17:
         _fx_free_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMkArray); break;
      case 18:
         _fx_free_T2LT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMkVector); break;
      case 19:
         _fx_free_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t(
            &(*dst)->u.KExpAt);
         break;
      case 20:
         _fx_free_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMem); break;
      case 21:
         _fx_free_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t(&(*dst)->u.KExpAssign); break;
      case 22:
         _fx_free_T2LT2LN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpMatch); break;
      case 23:
         _fx_free_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpTryCatch); break;
      case 25:
         _fx_free_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpCast); break;
      case 26:
         _fx_free_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t(
            &(*dst)->u.KExpMap);
         break;
      case 27:
         _fx_free_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t(
            &(*dst)->u.KExpFor);
         break;
      case 28:
         _fx_free_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t(&(*dst)->u.KExpWhile); break;
      case 29:
         _fx_free_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t(&(*dst)->u.KExpDoWhile); break;
      case 30:
         _fx_free_T2ST2N14K_form__ktyp_tR10Ast__loc_t(&(*dst)->u.KExpCCode); break;
      case 31:
         _fx_free_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t(&(*dst)->u.KDefVal); break;
      case 32:
         _fx_free_rR17K_form__kdeffun_t(&(*dst)->u.KDefFun); break;
      case 33:
         _fx_free_rR17K_form__kdefexn_t(&(*dst)->u.KDefExn); break;
      case 34:
         _fx_free_rR21K_form__kdefvariant_t(&(*dst)->u.KDefVariant); break;
      case 35:
         _fx_free_rR23K_form__kdefinterface_t(&(*dst)->u.KDefInterface); break;
      case 36:
         _fx_free_rR17K_form__kdeftyp_t(&(*dst)->u.KDefTyp); break;
      case 37:
         _fx_free_rR25K_form__kdefclosurevars_t(&(*dst)->u.KDefClosureVars); break;
      default:
         ;
      }
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_R17K_form__kmodule_t(struct _fx_R17K_form__kmodule_t* dst)
{
   fx_free_str(&dst->km_cname);
   _fx_free_LN14K_form__kexp_t(&dst->km_top);
   fx_free_list_simple(&dst->km_deps);
   _fx_free_R14Ast__pragmas_t(&dst->km_pragmas);
}

static void _fx_copy_R17K_form__kmodule_t(struct _fx_R17K_form__kmodule_t* src, struct _fx_R17K_form__kmodule_t* dst)
{
   dst->km_name = src->km_name;
   dst->km_idx = src->km_idx;
   dst->km_toposort_idx = src->km_toposort_idx;
   fx_copy_str(&src->km_cname, &dst->km_cname);
   FX_COPY_PTR(src->km_top, &dst->km_top);
   FX_COPY_PTR(src->km_deps, &dst->km_deps);
   dst->km_skip = src->km_skip;
   dst->km_main = src->km_main;
   _fx_copy_R14Ast__pragmas_t(&src->km_pragmas, &dst->km_pragmas);
}

static void _fx_make_R17K_form__kmodule_t(
   struct _fx_R9Ast__id_t* r_km_name,
   int_ r_km_idx,
   int_ r_km_toposort_idx,
   fx_str_t* r_km_cname,
   struct _fx_LN14K_form__kexp_t_data_t* r_km_top,
   struct _fx_Li_data_t* r_km_deps,
   bool r_km_skip,
   bool r_km_main,
   struct _fx_R14Ast__pragmas_t* r_km_pragmas,
   struct _fx_R17K_form__kmodule_t* fx_result)
{
   fx_result->km_name = *r_km_name;
   fx_result->km_idx = r_km_idx;
   fx_result->km_toposort_idx = r_km_toposort_idx;
   fx_copy_str(r_km_cname, &fx_result->km_cname);
   FX_COPY_PTR(r_km_top, &fx_result->km_top);
   FX_COPY_PTR(r_km_deps, &fx_result->km_deps);
   fx_result->km_skip = r_km_skip;
   fx_result->km_main = r_km_main;
   _fx_copy_R14Ast__pragmas_t(r_km_pragmas, &fx_result->km_pragmas);
}

static void _fx_free_LR17K_form__kmodule_t(struct _fx_LR17K_form__kmodule_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LR17K_form__kmodule_t, _fx_free_R17K_form__kmodule_t);
}

static int _fx_cons_LR17K_form__kmodule_t(
   struct _fx_R17K_form__kmodule_t* hd,
   struct _fx_LR17K_form__kmodule_t_data_t* tl,
   bool addref_tl,
   struct _fx_LR17K_form__kmodule_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LR17K_form__kmodule_t, _fx_copy_R17K_form__kmodule_t);
}

static void _fx_free_rNt10Hashset__t1R9Ast__id_t(struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rNt10Hashset__t1R9Ast__id_t, _fx_free_Nt10Hashset__t1R9Ast__id_t);
}

static int _fx_make_rNt10Hashset__t1R9Ast__id_t(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* arg,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rNt10Hashset__t1R9Ast__id_t, FX_COPY_PTR);
}

static void _fx_free_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti(
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti* dst)
{
   fx_free_arr(&dst->t4);
   fx_free_arr(&dst->t5);
}

static void _fx_copy_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti(
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti* src,
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   dst->t2 = src->t2;
   dst->t3 = src->t3;
   fx_copy_arr(&src->t4, &dst->t4);
   fx_copy_arr(&src->t5, &dst->t5);
}

static void _fx_make_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti(
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti* t0,
   int_ t1,
   int_ t2,
   int_ t3,
   fx_arr_t* t4,
   fx_arr_t* t5,
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti* fx_result)
{
   fx_result->t0 = *t0;
   fx_result->t1 = t1;
   fx_result->t2 = t2;
   fx_result->t3 = t3;
   fx_copy_arr(t4, &fx_result->t4);
   fx_copy_arr(t5, &fx_result->t5);
}

static void _fx_free_Nt10Hashmap__t2R9Ast__id_ti(struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      _fx_free_T6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti(&(*dst)->u.t);
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_Nt6option1rR23C_form__cdefinterface_t(struct _fx_Nt6option1rR23C_form__cdefinterface_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_rR23C_form__cdefinterface_t(&dst->u.Some); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_Nt6option1rR23C_form__cdefinterface_t(
   struct _fx_Nt6option1rR23C_form__cdefinterface_t* src,
   struct _fx_Nt6option1rR23C_form__cdefinterface_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      FX_COPY_PTR(src->u.Some, &dst->u.Some); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_Nt6option1N14C_form__ctyp_t(struct _fx_Nt6option1N14C_form__ctyp_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_N14C_form__ctyp_t(&dst->u.Some); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_Nt6option1N14C_form__ctyp_t(
   struct _fx_Nt6option1N14C_form__ctyp_t* src,
   struct _fx_Nt6option1N14C_form__ctyp_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      FX_COPY_PTR(src->u.Some, &dst->u.Some); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* dst)
{
   _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* src,
   struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_Nt6option1R9Ast__id_t* t0,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* t1,
   struct _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LN14C_form__ctyp_t(struct _fx_LN14C_form__ctyp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN14C_form__ctyp_t, _fx_free_N14C_form__ctyp_t);
}

static int _fx_cons_LN14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* hd,
   struct _fx_LN14C_form__ctyp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN14C_form__ctyp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN14C_form__ctyp_t, FX_COPY_PTR);
}

static void _fx_free_T2LN14C_form__ctyp_tN14C_form__ctyp_t(struct _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t* dst)
{
   _fx_free_LN14C_form__ctyp_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2LN14C_form__ctyp_tN14C_form__ctyp_t(
   struct _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t* src,
   struct _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LN14C_form__ctyp_tN14C_form__ctyp_t(
   struct _fx_LN14C_form__ctyp_t_data_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static int _fx_cons_LN19C_form__ctyp_attr_t(
   struct _fx_N19C_form__ctyp_attr_t* hd,
   struct _fx_LN19C_form__ctyp_attr_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN19C_form__ctyp_attr_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN19C_form__ctyp_attr_t, FX_COPY_SIMPLE_BY_PTR);
}

static void _fx_free_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* dst)
{
   fx_free_list_simple(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(
   struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* src,
   struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(
   struct _fx_LN19C_form__ctyp_attr_t_data_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T2iN14C_form__ctyp_t(struct _fx_T2iN14C_form__ctyp_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2iN14C_form__ctyp_t(struct _fx_T2iN14C_form__ctyp_t* src, struct _fx_T2iN14C_form__ctyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2iN14C_form__ctyp_t(
   int_ t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_T2iN14C_form__ctyp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_N14C_form__ctyp_t(struct _fx_N14C_form__ctyp_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      switch ((*dst)->tag) {
      case 14:
         _fx_free_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t(&(*dst)->u.CTypStruct); break;
      case 15:
         _fx_free_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t(&(*dst)->u.CTypUnion); break;
      case 16:
         _fx_free_T2LN14C_form__ctyp_tN14C_form__ctyp_t(&(*dst)->u.CTypFunRawPtr); break;
      case 17:
         _fx_free_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(&(*dst)->u.CTypRawPtr); break;
      case 18:
         _fx_free_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(&(*dst)->u.CTypRawArray); break;
      case 19:
         _fx_free_T2iN14C_form__ctyp_t(&(*dst)->u.CTypArray); break;
      case 20:
         _fx_free_N14C_form__ctyp_t(&(*dst)->u.CTypVector); break;
      default:
         ;
      }
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t0);
}

static void _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* t0,
   struct _fx_R10Ast__loc_t* t1,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t1,
   struct _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14K_form__klit_t(&dst->t0);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_copy_N14K_form__klit_t(&src->t0, &dst->t0);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14K_form__klit_t* t0,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t1,
   struct _fx_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   _fx_copy_N14K_form__klit_t(t0, &fx_result->t0);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t3);
}

static void _fx_copy_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void _fx_make_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N17C_form__cbinary_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t3,
   struct _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N16C_form__cunary_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t2,
   struct _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_R9Ast__id_t* t1,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t2,
   struct _fx_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t3);
}

static void _fx_copy_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t3, &dst->t3);
}

static void _fx_make_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t3,
   struct _fx_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t3, &fx_result->t3);
}

static void _fx_free_LN14C_form__cexp_t(struct _fx_LN14C_form__cexp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LN14C_form__cexp_t, _fx_free_N14C_form__cexp_t);
}

static int _fx_cons_LN14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* hd,
   struct _fx_LN14C_form__cexp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LN14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LN14C_form__cexp_t, FX_COPY_PTR);
}

static void _fx_free_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t2);
}

static void _fx_copy_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t2, &dst->t2);
}

static void _fx_make_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t2,
   struct _fx_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t2, &fx_result->t2);
}

static void _fx_free_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&dst->t1);
}

static void _fx_copy_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* src,
   struct _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(&src->t1, &dst->t1);
}

static void _fx_make_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* t1,
   struct _fx_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   _fx_copy_T2N14C_form__ctyp_tR10Ast__loc_t(t1, &fx_result->t1);
}

static void _fx_free_N14C_form__cexp_t(struct _fx_N14C_form__cexp_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      switch ((*dst)->tag) {
      case 1:
         _fx_free_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpIdent); break;
      case 2:
         _fx_free_T2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpLit); break;
      case 3:
         _fx_free_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &(*dst)->u.CExpBinary);
         break;
      case 4:
         _fx_free_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpUnary); break;
      case 5:
         _fx_free_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpMem); break;
      case 6:
         _fx_free_T3N14C_form__cexp_tR9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpArrow); break;
      case 7:
         _fx_free_T3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpCast); break;
      case 8:
         _fx_free_T4N14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpTernary);
         break;
      case 9:
         _fx_free_T3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpCall); break;
      case 10:
         _fx_free_T2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpInit); break;
      case 11:
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&(*dst)->u.CExpTyp); break;
      case 12:
         _fx_free_T2SR10Ast__loc_t(&(*dst)->u.CExpCCode); break;
      default:
         ;
      }
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t(struct _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t* dst)
{
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t0);
}

static void _fx_copy_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t* src,
   struct _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t* dst)
{
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_Nt6option1N14C_form__cexp_t* t0,
   struct _fx_R10Ast__loc_t* t1,
   struct _fx_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t* fx_result)
{
   _fx_copy_Nt6option1N14C_form__cexp_t(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_T2LN15C_form__cstmt_tR10Ast__loc_t(struct _fx_T2LN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   _fx_free_LN15C_form__cstmt_t(&dst->t0);
}

static void _fx_copy_T2LN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T2LN15C_form__cstmt_tR10Ast__loc_t* src,
   struct _fx_T2LN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2LN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_LN15C_form__cstmt_t_data_t* t0,
   struct _fx_R10Ast__loc_t* t1,
   struct _fx_T2LN15C_form__cstmt_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_T2R9Ast__id_tN15C_form__cstmt_t(struct _fx_T2R9Ast__id_tN15C_form__cstmt_t* dst)
{
   _fx_free_N15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tN15C_form__cstmt_t(
   struct _fx_T2R9Ast__id_tN15C_form__cstmt_t* src,
   struct _fx_T2R9Ast__id_tN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tN15C_form__cstmt_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N15C_form__cstmt_t_data_t* t1,
   struct _fx_T2R9Ast__id_tN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_N15C_form__cstmt_t(&dst->t1);
   _fx_free_N15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t* src,
   struct _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   dst->t3 = src->t3;
}

static void _fx_make_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_N15C_form__cstmt_t_data_t* t1,
   struct _fx_N15C_form__cstmt_t_data_t* t2,
   struct _fx_R10Ast__loc_t* t3,
   struct _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   fx_result->t3 = *t3;
}

static void
   _fx_free_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t*
      dst)
{
   _fx_free_Nt6option1N14C_form__ctyp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
   _fx_free_N15C_form__cstmt_t(&dst->t4);
}

static void
   _fx_copy_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t*
      src,
   struct _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t*
      dst)
{
   _fx_copy_Nt6option1N14C_form__ctyp_t(&src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
   dst->t5 = src->t5;
}

static void
   _fx_make_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_Nt6option1N14C_form__ctyp_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_Nt6option1N14C_form__cexp_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_N15C_form__cstmt_t_data_t* t4,
   struct _fx_R10Ast__loc_t* t5,
   struct _fx_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t*
      fx_result)
{
   _fx_copy_Nt6option1N14C_form__ctyp_t(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_Nt6option1N14C_form__cexp_t(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
   fx_result->t5 = *t5;
}

static void _fx_free_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_N15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t* src,
   struct _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_N15C_form__cstmt_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
   struct _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t* dst)
{
   _fx_free_N15C_form__cstmt_t(&dst->t0);
   _fx_free_N14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
   struct _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t* src,
   struct _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
   struct _fx_N15C_form__cstmt_t_data_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LT2LN14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t, _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t);
}

static int _fx_cons_LT2LN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t* hd,
   struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t, _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t);
}

static void _fx_free_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LT2LN14C_form__cexp_tLN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t* src,
   struct _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LT2LN14C_form__cexp_tLN15C_form__cstmt_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t0);
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t2);
}

static void _fx_copy_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t* src,
   struct _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t2, &dst->t2);
   dst->t3 = src->t3;
}

static void _fx_make_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* t0,
   struct _fx_R9Ast__id_t* t1,
   struct _fx_Nt6option1N14C_form__cexp_t* t2,
   struct _fx_R10Ast__loc_t* t3,
   struct _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
   _fx_copy_Nt6option1N14C_form__cexp_t(t2, &fx_result->t2);
   fx_result->t3 = *t3;
}

static void _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LT2N14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t, _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t);
}

static int _fx_cons_LT2N14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* hd,
   struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t, _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t);
}

static void _fx_free_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   _fx_free_LT2N14C_form__cexp_tLN15C_form__cstmt_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t* src,
   struct _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_LT2N14C_form__cexp_tLN15C_form__cstmt_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_N15C_form__cstmt_t(struct _fx_N15C_form__cstmt_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      switch ((*dst)->tag) {
      case 2:
         _fx_free_T2SR10Ast__loc_t(&(*dst)->u.CComment); break;
      case 3:
         _fx_free_N14C_form__cexp_t(&(*dst)->u.CExp); break;
      case 6:
         _fx_free_T2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&(*dst)->u.CStmtReturn); break;
      case 7:
         _fx_free_T2LN15C_form__cstmt_tR10Ast__loc_t(&(*dst)->u.CStmtBlock); break;
      case 8:
         _fx_free_T2R9Ast__id_tN15C_form__cstmt_t(&(*dst)->u.CStmtSync); break;
      case 9:
         _fx_free_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(&(*dst)->u.CStmtIf); break;
      case 12:
         _fx_free_T6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
            &(*dst)->u.CStmtFor);
         break;
      case 13:
         _fx_free_T3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(&(*dst)->u.CStmtWhile); break;
      case 14:
         _fx_free_T3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(&(*dst)->u.CStmtDoWhile); break;
      case 15:
         _fx_free_T3N14C_form__cexp_tLT2LN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(&(*dst)->u.CStmtSwitch); break;
      case 16:
         _fx_free_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(&(*dst)->u.CDefVal); break;
      case 17:
         _fx_free_rR17C_form__cdeffun_t(&(*dst)->u.CDefFun); break;
      case 18:
         _fx_free_rR17C_form__cdeftyp_t(&(*dst)->u.CDefTyp); break;
      case 21:
         _fx_free_rR18C_form__cdefenum_t(&(*dst)->u.CDefEnum); break;
      case 22:
         _fx_free_rR23C_form__cdefinterface_t(&(*dst)->u.CDefInterface); break;
      case 23:
         _fx_free_rR19C_form__cdefmacro_t(&(*dst)->u.CMacroDef); break;
      case 25:
         _fx_free_T3LT2N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tR10Ast__loc_t(&(*dst)->u.CMacroIf); break;
      case 26:
         _fx_free_T2SR10Ast__loc_t(&(*dst)->u.CMacroInclude); break;
      case 27:
         _fx_free_T2SR10Ast__loc_t(&(*dst)->u.CMacroPragma); break;
      default:
         ;
      }
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_T2SR9Ast__id_t(struct _fx_T2SR9Ast__id_t* dst)
{
   fx_free_str(&dst->t0);
}

static void _fx_copy_T2SR9Ast__id_t(struct _fx_T2SR9Ast__id_t* src, struct _fx_T2SR9Ast__id_t* dst)
{
   fx_copy_str(&src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2SR9Ast__id_t(fx_str_t* t0, struct _fx_R9Ast__id_t* t1, struct _fx_T2SR9Ast__id_t* fx_result)
{
   fx_copy_str(t0, &fx_result->t0);
   fx_result->t1 = *t1;
}

static void _fx_free_T2BNt6option1N14C_form__cexp_t(struct _fx_T2BNt6option1N14C_form__cexp_t* dst)
{
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T2BNt6option1N14C_form__cexp_t(
   struct _fx_T2BNt6option1N14C_form__cexp_t* src,
   struct _fx_T2BNt6option1N14C_form__cexp_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t1, &dst->t1);
}

static void _fx_make_T2BNt6option1N14C_form__cexp_t(
   bool t0,
   struct _fx_Nt6option1N14C_form__cexp_t* t1,
   struct _fx_T2BNt6option1N14C_form__cexp_t* fx_result)
{
   fx_result->t0 = t0;
   _fx_copy_Nt6option1N14C_form__cexp_t(t1, &fx_result->t1);
}

static void _fx_free_Ta3LN15C_form__cstmt_t(struct _fx_Ta3LN15C_form__cstmt_t* dst)
{
   _fx_free_LN15C_form__cstmt_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_Ta3LN15C_form__cstmt_t(struct _fx_Ta3LN15C_form__cstmt_t* src, struct _fx_Ta3LN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_Ta3LN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_Ta3LN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_rLN15C_form__cstmt_t(struct _fx_rLN15C_form__cstmt_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rLN15C_form__cstmt_t, _fx_free_LN15C_form__cstmt_t);
}

static int _fx_make_rLN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* arg,
   struct _fx_rLN15C_form__cstmt_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rLN15C_form__cstmt_t, FX_COPY_PTR);
}

static void _fx_free_R23C_gen_code__block_ctx_t(struct _fx_R23C_gen_code__block_ctx_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->bctx_status);
   _fx_free_N14C_form__cexp_t(&dst->bctx_par_status);
   _fx_free_LN15C_form__cstmt_t(&dst->bctx_prologue);
   _fx_free_LN15C_form__cstmt_t(&dst->bctx_cleanup);
}

static void _fx_copy_R23C_gen_code__block_ctx_t(
   struct _fx_R23C_gen_code__block_ctx_t* src,
   struct _fx_R23C_gen_code__block_ctx_t* dst)
{
   dst->bctx_kind = src->bctx_kind;
   dst->bctx_label = src->bctx_label;
   dst->bctx_br_label = src->bctx_br_label;
   dst->bctx_for_flags = src->bctx_for_flags;
   FX_COPY_PTR(src->bctx_status, &dst->bctx_status);
   FX_COPY_PTR(src->bctx_par_status, &dst->bctx_par_status);
   FX_COPY_PTR(src->bctx_prologue, &dst->bctx_prologue);
   FX_COPY_PTR(src->bctx_cleanup, &dst->bctx_cleanup);
   dst->bctx_break_used = src->bctx_break_used;
   dst->bctx_continue_used = src->bctx_continue_used;
   dst->bctx_return_used = src->bctx_return_used;
   dst->bctx_label_used = src->bctx_label_used;
}

static void _fx_make_R23C_gen_code__block_ctx_t(
   struct _fx_N24C_gen_code__block_kind_t* r_bctx_kind,
   struct _fx_R9Ast__id_t* r_bctx_label,
   struct _fx_R9Ast__id_t* r_bctx_br_label,
   struct _fx_R16Ast__for_flags_t* r_bctx_for_flags,
   struct _fx_N14C_form__cexp_t_data_t* r_bctx_status,
   struct _fx_N14C_form__cexp_t_data_t* r_bctx_par_status,
   struct _fx_LN15C_form__cstmt_t_data_t* r_bctx_prologue,
   struct _fx_LN15C_form__cstmt_t_data_t* r_bctx_cleanup,
   int_ r_bctx_break_used,
   int_ r_bctx_continue_used,
   int_ r_bctx_return_used,
   int_ r_bctx_label_used,
   struct _fx_R23C_gen_code__block_ctx_t* fx_result)
{
   fx_result->bctx_kind = *r_bctx_kind;
   fx_result->bctx_label = *r_bctx_label;
   fx_result->bctx_br_label = *r_bctx_br_label;
   fx_result->bctx_for_flags = *r_bctx_for_flags;
   FX_COPY_PTR(r_bctx_status, &fx_result->bctx_status);
   FX_COPY_PTR(r_bctx_par_status, &fx_result->bctx_par_status);
   FX_COPY_PTR(r_bctx_prologue, &fx_result->bctx_prologue);
   FX_COPY_PTR(r_bctx_cleanup, &fx_result->bctx_cleanup);
   fx_result->bctx_break_used = r_bctx_break_used;
   fx_result->bctx_continue_used = r_bctx_continue_used;
   fx_result->bctx_return_used = r_bctx_return_used;
   fx_result->bctx_label_used = r_bctx_label_used;
}

static void _fx_free_rR23C_gen_code__block_ctx_t(struct _fx_rR23C_gen_code__block_ctx_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rR23C_gen_code__block_ctx_t, _fx_free_R23C_gen_code__block_ctx_t);
}

static int _fx_make_rR23C_gen_code__block_ctx_t(
   struct _fx_R23C_gen_code__block_ctx_t* arg,
   struct _fx_rR23C_gen_code__block_ctx_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rR23C_gen_code__block_ctx_t, _fx_copy_R23C_gen_code__block_ctx_t);
}

static void _fx_free_Nt6option1rR23C_gen_code__block_ctx_t(struct _fx_Nt6option1rR23C_gen_code__block_ctx_t* dst)
{
   switch (dst->tag) {
   case 2:
      _fx_free_rR23C_gen_code__block_ctx_t(&dst->u.Some); break;
   default:
      ;
   }
   dst->tag = 0;
}

static void _fx_copy_Nt6option1rR23C_gen_code__block_ctx_t(
   struct _fx_Nt6option1rR23C_gen_code__block_ctx_t* src,
   struct _fx_Nt6option1rR23C_gen_code__block_ctx_t* dst)
{
   dst->tag = src->tag;
   switch (src->tag) {
   case 2:
      FX_COPY_PTR(src->u.Some, &dst->u.Some); break;
   default:
      dst->u = src->u;
   }
}

static void _fx_free_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* dst)
{
   _fx_free_Nt6option1N14C_form__ctyp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
}

static void _fx_copy_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* src,
   struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* dst)
{
   _fx_copy_Nt6option1N14C_form__ctyp_t(&src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void _fx_make_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_Nt6option1N14C_form__ctyp_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_Nt6option1N14C_form__cexp_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* fx_result)
{
   _fx_copy_Nt6option1N14C_form__ctyp_t(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_Nt6option1N14C_form__cexp_t(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t,
      _fx_free_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t);
}

static int _fx_cons_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* hd,
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t,
      _fx_copy_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t);
}

static void _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
   _fx_free_N14C_form__cexp_t(&dst->t3);
   _fx_free_N14C_form__cexp_t(&dst->t4);
}

static void _fx_copy_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* src,
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
}

static void _fx_make_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_N14C_form__ctyp_t_data_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_N14C_form__cexp_t_data_t* t3,
   struct _fx_N14C_form__cexp_t_data_t* t4,
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
}

static void _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t,
      _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t);
}

static int _fx_cons_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* hd,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t,
      _fx_copy_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t);
}

static void _fx_free_LLN15C_form__cstmt_t(struct _fx_LLN15C_form__cstmt_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LLN15C_form__cstmt_t, _fx_free_LN15C_form__cstmt_t);
}

static int _fx_cons_LLN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* hd,
   struct _fx_LLN15C_form__cstmt_t_data_t* tl,
   bool addref_tl,
   struct _fx_LLN15C_form__cstmt_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LLN15C_form__cstmt_t, FX_COPY_PTR);
}

static void _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->data);
}

static void _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* src,
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* dst)
{
   dst->hv = src->hv;
   dst->key = src->key;
   FX_COPY_PTR(src->data, &dst->data);
}

static void _fx_make_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   uint64_t r_hv,
   struct _fx_R9Ast__id_t* r_key,
   struct _fx_N14C_form__cexp_t_data_t* r_data,
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* fx_result)
{
   fx_result->hv = r_hv;
   fx_result->key = *r_key;
   FX_COPY_PTR(r_data, &fx_result->data);
}

static void
   _fx_free_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t*
      dst)
{
   _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&dst->t0);
   fx_free_arr(&dst->t4);
   fx_free_arr(&dst->t5);
}

static void
   _fx_copy_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t*
      src,
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t*
      dst)
{
   _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&src->t0, &dst->t0);
   dst->t1 = src->t1;
   dst->t2 = src->t2;
   dst->t3 = src->t3;
   fx_copy_arr(&src->t4, &dst->t4);
   fx_copy_arr(&src->t5, &dst->t5);
}

static void
   _fx_make_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* t0,
   int_ t1,
   int_ t2,
   int_ t3,
   fx_arr_t* t4,
   fx_arr_t* t5,
   struct _fx_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t*
      fx_result)
{
   _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(t0, &fx_result->t0);
   fx_result->t1 = t1;
   fx_result->t2 = t2;
   fx_result->t3 = t3;
   fx_copy_arr(t4, &fx_result->t4);
   fx_copy_arr(t5, &fx_result->t5);
}

static void _fx_free_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t** dst)
{
   if (*dst && FX_DECREF((*dst)->rc) == 1) {
      _fx_free_T6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
         &(*dst)->u.t);
      fx_free(*dst);
   }
   *dst = 0;
}

static void _fx_free_R17C_form__cmodule_t(struct _fx_R17C_form__cmodule_t* dst)
{
   fx_free_str(&dst->cmod_cname);
   _fx_free_LN15C_form__cstmt_t(&dst->cmod_ccode);
   _fx_free_R14Ast__pragmas_t(&dst->cmod_pragmas);
}

static void _fx_copy_R17C_form__cmodule_t(struct _fx_R17C_form__cmodule_t* src, struct _fx_R17C_form__cmodule_t* dst)
{
   dst->cmod_name = src->cmod_name;
   fx_copy_str(&src->cmod_cname, &dst->cmod_cname);
   FX_COPY_PTR(src->cmod_ccode, &dst->cmod_ccode);
   dst->cmod_main = src->cmod_main;
   dst->cmod_recompile = src->cmod_recompile;
   dst->cmod_skip = src->cmod_skip;
   _fx_copy_R14Ast__pragmas_t(&src->cmod_pragmas, &dst->cmod_pragmas);
}

static void _fx_make_R17C_form__cmodule_t(
   struct _fx_R9Ast__id_t* r_cmod_name,
   fx_str_t* r_cmod_cname,
   struct _fx_LN15C_form__cstmt_t_data_t* r_cmod_ccode,
   bool r_cmod_main,
   bool r_cmod_recompile,
   bool r_cmod_skip,
   struct _fx_R14Ast__pragmas_t* r_cmod_pragmas,
   struct _fx_R17C_form__cmodule_t* fx_result)
{
   fx_result->cmod_name = *r_cmod_name;
   fx_copy_str(r_cmod_cname, &fx_result->cmod_cname);
   FX_COPY_PTR(r_cmod_ccode, &fx_result->cmod_ccode);
   fx_result->cmod_main = r_cmod_main;
   fx_result->cmod_recompile = r_cmod_recompile;
   fx_result->cmod_skip = r_cmod_skip;
   _fx_copy_R14Ast__pragmas_t(r_cmod_pragmas, &fx_result->cmod_pragmas);
}

static void _fx_free_rNt10Hashmap__t2R9Ast__id_ti(struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rNt10Hashmap__t2R9Ast__id_ti, _fx_free_Nt10Hashmap__t2R9Ast__id_ti);
}

static int _fx_make_rNt10Hashmap__t2R9Ast__id_ti(
   struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t* arg,
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rNt10Hashmap__t2R9Ast__id_ti, FX_COPY_PTR);
}

static void _fx_free_Ta3LS(struct _fx_Ta3LS* dst)
{
   _fx_free_LS(&dst->t0);
   _fx_free_LS(&dst->t1);
   _fx_free_LS(&dst->t2);
}

static void _fx_copy_Ta3LS(struct _fx_Ta3LS* src, struct _fx_Ta3LS* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_Ta3LS(
   struct _fx_LS_data_t* t0,
   struct _fx_LS_data_t* t1,
   struct _fx_LS_data_t* t2,
   struct _fx_Ta3LS* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&dst->t2);
}

static void _fx_copy_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* src,
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   dst->t3 = src->t3;
}

static void _fx_make_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* t2,
   int_ t3,
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   fx_result->t3 = t3;
}

static void _fx_free_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB(
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB* dst)
{
   _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t2);
}

static void _fx_copy_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB(
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB* src,
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   FX_COPY_PTR(src->t2, &dst->t2);
   dst->t3 = src->t3;
}

static void _fx_make_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0,
   struct _fx_R9Ast__id_t* t1,
   struct _fx_N14C_form__ctyp_t_data_t* t2,
   bool t3,
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
   FX_COPY_PTR(t2, &fx_result->t2);
   fx_result->t3 = t3;
}

static void _fx_free_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB(
   struct _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB* dst)
{
   _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&dst->t0);
}

static void _fx_copy_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB(
   struct _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB* src,
   struct _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0,
   bool t1,
   struct _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = t1;
}

static void _fx_free_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t* dst)
{
   _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t2);
}

static void _fx_copy_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t* src,
   struct _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0,
   struct _fx_R9Ast__id_t* t1,
   struct _fx_N14C_form__ctyp_t_data_t* t2,
   struct _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_Ta3N14C_form__cexp_t(struct _fx_Ta3N14C_form__cexp_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
}

static void _fx_copy_Ta3N14C_form__cexp_t(struct _fx_Ta3N14C_form__cexp_t* src, struct _fx_Ta3N14C_form__cexp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_Ta3N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_Ta3N14C_form__cexp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T2N14C_form__cexp_tN14C_form__ctyp_t(struct _fx_T2N14C_form__cexp_tN14C_form__ctyp_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2N14C_form__cexp_tN14C_form__ctyp_t(
   struct _fx_T2N14C_form__cexp_tN14C_form__ctyp_t* src,
   struct _fx_T2N14C_form__cexp_tN14C_form__ctyp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2N14C_form__cexp_tN14C_form__ctyp_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_T2N14C_form__cexp_tN14C_form__ctyp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_LR17C_form__cmodule_t(struct _fx_LR17C_form__cmodule_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LR17C_form__cmodule_t, _fx_free_R17C_form__cmodule_t);
}

static int _fx_cons_LR17C_form__cmodule_t(
   struct _fx_R17C_form__cmodule_t* hd,
   struct _fx_LR17C_form__cmodule_t_data_t* tl,
   bool addref_tl,
   struct _fx_LR17C_form__cmodule_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LR17C_form__cmodule_t, _fx_copy_R17C_form__cmodule_t);
}

static void _fx_free_Ta2LN15C_form__cstmt_t(struct _fx_Ta2LN15C_form__cstmt_t* dst)
{
   _fx_free_LN15C_form__cstmt_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_Ta2LN15C_form__cstmt_t(struct _fx_Ta2LN15C_form__cstmt_t* src, struct _fx_Ta2LN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_Ta2LN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_Ta2LN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t, _fx_free_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t);
}

static int _fx_make_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t, FX_COPY_PTR);
}

static void _fx_free_LrR23C_gen_code__block_ctx_t(struct _fx_LrR23C_gen_code__block_ctx_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LrR23C_gen_code__block_ctx_t, _fx_free_rR23C_gen_code__block_ctx_t);
}

static int _fx_cons_LrR23C_gen_code__block_ctx_t(
   struct _fx_rR23C_gen_code__block_ctx_t_data_t* hd,
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t* tl,
   bool addref_tl,
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LrR23C_gen_code__block_ctx_t, FX_COPY_PTR);
}

static void _fx_free_rLrR23C_gen_code__block_ctx_t(struct _fx_rLrR23C_gen_code__block_ctx_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rLrR23C_gen_code__block_ctx_t, _fx_free_LrR23C_gen_code__block_ctx_t);
}

static int _fx_make_rLrR23C_gen_code__block_ctx_t(
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t* arg,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rLrR23C_gen_code__block_ctx_t, FX_COPY_PTR);
}

static void _fx_free_rNt6option1N14C_form__cexp_t(struct _fx_rNt6option1N14C_form__cexp_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rNt6option1N14C_form__cexp_t, _fx_free_Nt6option1N14C_form__cexp_t);
}

static int _fx_make_rNt6option1N14C_form__cexp_t(
   struct _fx_Nt6option1N14C_form__cexp_t* arg,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rNt6option1N14C_form__cexp_t, _fx_copy_Nt6option1N14C_form__cexp_t);
}

static void _fx_free_rrNt6option1N14C_form__cexp_t(struct _fx_rrNt6option1N14C_form__cexp_t_data_t** dst)
{
   FX_FREE_REF_IMPL(_fx_rrNt6option1N14C_form__cexp_t, _fx_free_rNt6option1N14C_form__cexp_t);
}

static int _fx_make_rrNt6option1N14C_form__cexp_t(
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* arg,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_REF_IMPL(_fx_rrNt6option1N14C_form__cexp_t, FX_COPY_PTR);
}

static void _fx_free_T3BN14C_form__cexp_tN14C_form__ctyp_t(struct _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_N14C_form__ctyp_t(&dst->t2);
}

static void _fx_copy_T3BN14C_form__cexp_tN14C_form__ctyp_t(
   struct _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t* src,
   struct _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3BN14C_form__cexp_tN14C_form__ctyp_t(
   bool t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_N14C_form__ctyp_t_data_t* t2,
   struct _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T2R9Ast__id_tLN15C_form__cstmt_t(struct _fx_T2R9Ast__id_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tLN15C_form__cstmt_t(
   struct _fx_T2R9Ast__id_tLN15C_form__cstmt_t* src,
   struct _fx_T2R9Ast__id_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tLN15C_form__cstmt_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2R9Ast__id_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(
   struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_R16Ast__val_flags_t(&dst->t2);
}

static void _fx_copy_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(
   struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t* src,
   struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   _fx_copy_R16Ast__val_flags_t(&src->t2, &dst->t2);
}

static void _fx_make_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_R16Ast__val_flags_t* t2,
   struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   _fx_copy_R16Ast__val_flags_t(t2, &fx_result->t2);
}

static void _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t,
      _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t);
}

static int _fx_cons_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(
   struct _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t* hd,
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t,
      _fx_copy_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t);
}

static void
   _fx_free_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t(
   struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*
      dst)
{
   _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
   _fx_free_LN15C_form__cstmt_t(&dst->t4);
   _fx_free_LN15C_form__cstmt_t(&dst->t5);
   _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&dst->t6);
   _fx_free_LN15C_form__cstmt_t(&dst->t7);
}

static void
   _fx_copy_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t(
   struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*
      src,
   struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*
      dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
   FX_COPY_PTR(src->t5, &dst->t5);
   FX_COPY_PTR(src->t6, &dst->t6);
   FX_COPY_PTR(src->t7, &dst->t7);
}

static void
   _fx_make_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t(
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_LN15C_form__cstmt_t_data_t* t4,
   struct _fx_LN15C_form__cstmt_t_data_t* t5,
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* t6,
   struct _fx_LN15C_form__cstmt_t_data_t* t7,
   struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*
      fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
   FX_COPY_PTR(t5, &fx_result->t5);
   FX_COPY_PTR(t6, &fx_result->t6);
   FX_COPY_PTR(t7, &fx_result->t7);
}

static void _fx_free_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(struct _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* dst)
{
   _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&dst->t0);
   fx_free_list_simple(&dst->t1);
}

static void _fx_copy_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* src,
   struct _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t0,
   struct _fx_LR9Ast__id_t_data_t* t1,
   struct _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void
   _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
   struct _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t*
      dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
   _fx_free_LN14C_form__cexp_t(&dst->t4);
   _fx_free_LN14C_form__cexp_t(&dst->t5);
   _fx_free_LN15C_form__cstmt_t(&dst->t6);
   _fx_free_LN15C_form__cstmt_t(&dst->t7);
   _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&dst->t8);
   _fx_free_LN14C_form__cexp_t(&dst->t9);
}

static void
   _fx_copy_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
   struct _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t*
      src,
   struct _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t*
      dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
   FX_COPY_PTR(src->t5, &dst->t5);
   FX_COPY_PTR(src->t6, &dst->t6);
   FX_COPY_PTR(src->t7, &dst->t7);
   FX_COPY_PTR(src->t8, &dst->t8);
   FX_COPY_PTR(src->t9, &dst->t9);
}

static void
   _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_LN14C_form__cexp_t_data_t* t4,
   struct _fx_LN14C_form__cexp_t_data_t* t5,
   struct _fx_LN15C_form__cstmt_t_data_t* t6,
   struct _fx_LN15C_form__cstmt_t_data_t* t7,
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* t8,
   struct _fx_LN14C_form__cexp_t_data_t* t9,
   struct _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t*
      fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
   FX_COPY_PTR(t5, &fx_result->t5);
   FX_COPY_PTR(t6, &fx_result->t6);
   FX_COPY_PTR(t7, &fx_result->t7);
   FX_COPY_PTR(t8, &fx_result->t8);
   FX_COPY_PTR(t9, &fx_result->t9);
}

static void _fx_free_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t2);
   _fx_free_LN15C_form__cstmt_t(&dst->t3);
}

static void _fx_copy_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void _fx_make_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_N17C_form__cbinary_t* t0,
   struct _fx_N17C_form__cbinary_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_LN15C_form__cstmt_t_data_t* t3,
   struct _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = *t0;
   fx_result->t1 = *t1;
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void _fx_free_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
   _fx_free_LN14C_form__cexp_t(&dst->t4);
   _fx_free_LN15C_form__cstmt_t(&dst->t5);
}

static void _fx_copy_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
   FX_COPY_PTR(src->t5, &dst->t5);
}

static void _fx_make_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   bool t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_LN14C_form__cexp_t_data_t* t4,
   struct _fx_LN15C_form__cstmt_t_data_t* t5,
   struct _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
   FX_COPY_PTR(t5, &fx_result->t5);
}

static void _fx_free_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
   _fx_free_LN15C_form__cstmt_t(&dst->t4);
}

static void _fx_copy_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
}

static void _fx_make_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_LN15C_form__cstmt_t_data_t* t4,
   struct _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
}

static void _fx_free_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN15C_form__cstmt_t(&dst->t3);
}

static void _fx_copy_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void _fx_make_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   struct _fx_LN15C_form__cstmt_t_data_t* t3,
   struct _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void _fx_free_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* dst)
{
   _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* src,
   struct _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   int_ t0,
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* t1,
   struct _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T2N14C_form__cexp_tLN14C_form__cexp_t(struct _fx_T2N14C_form__cexp_tLN14C_form__cexp_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T2N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_T2N14C_form__cexp_tLN14C_form__cexp_t* src,
   struct _fx_T2N14C_form__cexp_tLN14C_form__cexp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_T2N14C_form__cexp_tLN14C_form__cexp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T5BBBBLLN15C_form__cstmt_t(struct _fx_T5BBBBLLN15C_form__cstmt_t* dst)
{
   _fx_free_LLN15C_form__cstmt_t(&dst->t4);
}

static void _fx_copy_T5BBBBLLN15C_form__cstmt_t(
   struct _fx_T5BBBBLLN15C_form__cstmt_t* src,
   struct _fx_T5BBBBLLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   dst->t1 = src->t1;
   dst->t2 = src->t2;
   dst->t3 = src->t3;
   FX_COPY_PTR(src->t4, &dst->t4);
}

static void _fx_make_T5BBBBLLN15C_form__cstmt_t(
   bool t0,
   bool t1,
   bool t2,
   bool t3,
   struct _fx_LLN15C_form__cstmt_t_data_t* t4,
   struct _fx_T5BBBBLLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   fx_result->t1 = t1;
   fx_result->t2 = t2;
   fx_result->t3 = t3;
   FX_COPY_PTR(t4, &fx_result->t4);
}

static void _fx_free_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(struct _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_LLN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(
   struct _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t* src,
   struct _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_LLN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T3LN15C_form__cstmt_tBB(struct _fx_T3LN15C_form__cstmt_tBB* dst)
{
   _fx_free_LN15C_form__cstmt_t(&dst->t0);
}

static void _fx_copy_T3LN15C_form__cstmt_tBB(struct _fx_T3LN15C_form__cstmt_tBB* src, struct _fx_T3LN15C_form__cstmt_tBB* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   dst->t2 = src->t2;
}

static void _fx_make_T3LN15C_form__cstmt_tBB(
   struct _fx_LN15C_form__cstmt_t_data_t* t0,
   bool t1,
   bool t2,
   struct _fx_T3LN15C_form__cstmt_tBB* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = t1;
   fx_result->t2 = t2;
}

static void _fx_free_T2BLN15C_form__cstmt_t(struct _fx_T2BLN15C_form__cstmt_t* dst)
{
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2BLN15C_form__cstmt_t(struct _fx_T2BLN15C_form__cstmt_t* src, struct _fx_T2BLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2BLN15C_form__cstmt_t(
   bool t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2BLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T3BN14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T3BN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(
   bool t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(
   struct _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
   _fx_free_N14C_form__ctyp_t(&dst->t3);
}

static void _fx_copy_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(
   struct _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t* src,
   struct _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   dst->t4 = src->t4;
}

static void _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(
   bool t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_N14C_form__ctyp_t_data_t* t3,
   struct _fx_R9Ast__id_t* t4,
   struct _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   fx_result->t4 = *t4;
}

static void _fx_free_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(&src->t1, &dst->t1);
}

static void _fx_make_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t(
   bool t0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* t1,
   struct _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(t1, &fx_result->t1);
}

static void _fx_free_T2N17C_form__cbinary_tN14C_form__ctyp_t(struct _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_T2N17C_form__cbinary_tN14C_form__ctyp_t(
   struct _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t* src,
   struct _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(
   struct _fx_N17C_form__cbinary_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   struct _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t* fx_result)
{
   fx_result->t0 = *t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T2R9Ast__id_tN15C_form__cinfo_t(struct _fx_T2R9Ast__id_tN15C_form__cinfo_t* dst)
{
   _fx_free_N15C_form__cinfo_t(&dst->t1);
}

static void _fx_copy_T2R9Ast__id_tN15C_form__cinfo_t(
   struct _fx_T2R9Ast__id_tN15C_form__cinfo_t* src,
   struct _fx_T2R9Ast__id_tN15C_form__cinfo_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_N15C_form__cinfo_t(&src->t1, &dst->t1);
}

static void _fx_make_T2R9Ast__id_tN15C_form__cinfo_t(
   struct _fx_R9Ast__id_t* t0,
   struct _fx_N15C_form__cinfo_t* t1,
   struct _fx_T2R9Ast__id_tN15C_form__cinfo_t* fx_result)
{
   fx_result->t0 = *t0;
   _fx_copy_N15C_form__cinfo_t(t1, &fx_result->t1);
}

static void _fx_free_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t(
   struct _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN15C_form__cstmt_t(&dst->t4);
}

static void _fx_copy_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t(
   struct _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t* src,
   struct _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   FX_COPY_PTR(src->t2, &dst->t2);
   dst->t3 = src->t3;
   FX_COPY_PTR(src->t4, &dst->t4);
}

static void _fx_make_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   bool t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   bool t3,
   struct _fx_LN15C_form__cstmt_t_data_t* t4,
   struct _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = t1;
   FX_COPY_PTR(t2, &fx_result->t2);
   fx_result->t3 = t3;
   FX_COPY_PTR(t4, &fx_result->t4);
}

static void _fx_free_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t0);
   _fx_free_N14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_LN14C_form__cexp_t_data_t* t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T2LN14K_form__atom_tS(struct _fx_T2LN14K_form__atom_tS* dst)
{
   _fx_free_LN14K_form__atom_t(&dst->t0);
   fx_free_str(&dst->t1);
}

static void _fx_copy_T2LN14K_form__atom_tS(struct _fx_T2LN14K_form__atom_tS* src, struct _fx_T2LN14K_form__atom_tS* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   fx_copy_str(&src->t1, &dst->t1);
}

static void _fx_make_T2LN14K_form__atom_tS(
   struct _fx_LN14K_form__atom_t_data_t* t0,
   fx_str_t* t1,
   struct _fx_T2LN14K_form__atom_tS* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_copy_str(t1, &fx_result->t1);
}

static void _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN14C_form__cexp_t(&dst->t2);
   _fx_free_LN14C_form__cexp_t(&dst->t3);
   _fx_free_LN15C_form__cstmt_t(&dst->t4);
}

static void _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
   FX_COPY_PTR(src->t4, &dst->t4);
}

static void _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   int_ t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN14C_form__cexp_t_data_t* t2,
   struct _fx_LN14C_form__cexp_t_data_t* t3,
   struct _fx_LN15C_form__cstmt_t_data_t* t4,
   struct _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
   FX_COPY_PTR(t4, &fx_result->t4);
}

static void _fx_free_T2iN14C_form__cexp_t(struct _fx_T2iN14C_form__cexp_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T2iN14C_form__cexp_t(struct _fx_T2iN14C_form__cexp_t* src, struct _fx_T2iN14C_form__cexp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2iN14C_form__cexp_t(
   int_ t0,
   struct _fx_N14C_form__cexp_t_data_t* t1,
   struct _fx_T2iN14C_form__cexp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T3iLN14C_form__cexp_tN14C_form__cexp_t(struct _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
}

static void _fx_copy_T3iLN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t* src,
   struct _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3iLN14C_form__cexp_tN14C_form__cexp_t(
   int_ t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(&src->t1, &dst->t1);
}

static void _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(
   int_ t0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* t1,
   struct _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(t1, &fx_result->t1);
}

static void _fx_free_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t0);
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_Nt6option1N14C_form__cexp_t* t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   _fx_copy_Nt6option1N14C_form__cexp_t(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_Ta2N14K_form__kexp_t(struct _fx_Ta2N14K_form__kexp_t* dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t0);
   _fx_free_N14K_form__kexp_t(&dst->t1);
}

static void _fx_copy_Ta2N14K_form__kexp_t(struct _fx_Ta2N14K_form__kexp_t* src, struct _fx_Ta2N14K_form__kexp_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_Ta2N14K_form__kexp_t(
   struct _fx_N14K_form__kexp_t_data_t* t0,
   struct _fx_N14K_form__kexp_t_data_t* t1,
   struct _fx_Ta2N14K_form__kexp_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void _fx_free_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
   _fx_free_N14C_form__cexp_t(&dst->t2);
   _fx_free_LN15C_form__cstmt_t(&dst->t3);
}

static void _fx_copy_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void _fx_make_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_N14C_form__cexp_t_data_t* t2,
   struct _fx_LN15C_form__cstmt_t_data_t* t3,
   struct _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void
   _fx_free_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      dst)
{
   _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void
   _fx_copy_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      src,
   struct _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void
   _fx_make_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T3SSR10Ast__loc_t(struct _fx_T3SSR10Ast__loc_t* dst)
{
   fx_free_str(&dst->t0);
   fx_free_str(&dst->t1);
}

static void _fx_copy_T3SSR10Ast__loc_t(struct _fx_T3SSR10Ast__loc_t* src, struct _fx_T3SSR10Ast__loc_t* dst)
{
   fx_copy_str(&src->t0, &dst->t0);
   fx_copy_str(&src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3SSR10Ast__loc_t(
   fx_str_t* t0,
   fx_str_t* t1,
   struct _fx_R10Ast__loc_t* t2,
   struct _fx_T3SSR10Ast__loc_t* fx_result)
{
   fx_copy_str(t0, &fx_result->t0);
   fx_copy_str(t1, &fx_result->t1);
   fx_result->t2 = *t2;
}

static void _fx_free_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB(
   struct _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB* dst)
{
   _fx_free_R16Ast__val_flags_t(&dst->t0);
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB(
   struct _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB* src,
   struct _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB* dst)
{
   _fx_copy_R16Ast__val_flags_t(&src->t0, &dst->t0);
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t1, &dst->t1);
   dst->t2 = src->t2;
}

static void _fx_make_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB(
   struct _fx_R16Ast__val_flags_t* t0,
   struct _fx_Nt6option1N14C_form__cexp_t* t1,
   bool t2,
   struct _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB* fx_result)
{
   _fx_copy_R16Ast__val_flags_t(t0, &fx_result->t0);
   _fx_copy_Nt6option1N14C_form__cexp_t(t1, &fx_result->t1);
   fx_result->t2 = t2;
}

static void _fx_free_T2Nt6option1N14C_form__cexp_tB(struct _fx_T2Nt6option1N14C_form__cexp_tB* dst)
{
   _fx_free_Nt6option1N14C_form__cexp_t(&dst->t0);
}

static void _fx_copy_T2Nt6option1N14C_form__cexp_tB(
   struct _fx_T2Nt6option1N14C_form__cexp_tB* src,
   struct _fx_T2Nt6option1N14C_form__cexp_tB* dst)
{
   _fx_copy_Nt6option1N14C_form__cexp_t(&src->t0, &dst->t0);
   dst->t1 = src->t1;
}

static void _fx_make_T2Nt6option1N14C_form__cexp_tB(
   struct _fx_Nt6option1N14C_form__cexp_t* t0,
   bool t1,
   struct _fx_T2Nt6option1N14C_form__cexp_tB* fx_result)
{
   _fx_copy_Nt6option1N14C_form__cexp_t(t0, &fx_result->t0);
   fx_result->t1 = t1;
}

static void _fx_free_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t(
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t* dst)
{
   _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&dst->t0);
   _fx_free_N14C_form__ctyp_t(&dst->t1);
   _fx_free_rR17C_form__cdeffun_t(&dst->t3);
}

static void _fx_copy_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t(
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t* src,
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   dst->t2 = src->t2;
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void _fx_make_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* t0,
   struct _fx_N14C_form__ctyp_t_data_t* t1,
   bool t2,
   struct _fx_rR17C_form__cdeffun_t_data_t* t3,
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   fx_result->t2 = t2;
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void _fx_free_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t* dst)
{
   _fx_free_N14C_form__cexp_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t* src,
   struct _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_N14C_form__cexp_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t(
   struct _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t* dst)
{
   _fx_free_N14C_form__ctyp_t(&dst->t0);
}

static void _fx_copy_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t(
   struct _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t* src,
   struct _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   dst->t1 = src->t1;
   dst->t2 = src->t2;
   dst->t3 = src->t3;
   dst->t4 = src->t4;
}

static void _fx_make_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t(
   struct _fx_N14C_form__ctyp_t_data_t* t0,
   struct _fx_R9Ast__id_t* t1,
   bool t2,
   struct _fx_R9Ast__id_t* t3,
   struct _fx_R9Ast__id_t* t4,
   struct _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   fx_result->t1 = *t1;
   fx_result->t2 = t2;
   fx_result->t3 = *t3;
   fx_result->t4 = *t4;
}

static void
   _fx_free_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t*
      dst)
{
   _fx_free_N14K_form__kexp_t(&dst->t0);
   _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&dst->t1);
   fx_free_list_simple(&dst->t2);
   _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&dst->t3);
}

static void
   _fx_copy_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t*
      src,
   struct _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t*
      dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void
   _fx_make_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_N14K_form__kexp_t_data_t* t0,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* t1,
   struct _fx_LR9Ast__id_t_data_t* t2,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* t3,
   struct _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t*
      fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void _fx_free_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(struct _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
}

static void _fx_copy_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t* src,
   struct _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
}

static void _fx_make_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(
   int_ t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
}

static void _fx_free_T2iLN14C_form__cexp_t(struct _fx_T2iLN14C_form__cexp_t* dst)
{
   _fx_free_LN14C_form__cexp_t(&dst->t1);
}

static void _fx_copy_T2iLN14C_form__cexp_t(struct _fx_T2iLN14C_form__cexp_t* src, struct _fx_T2iLN14C_form__cexp_t* dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2iLN14C_form__cexp_t(
   int_ t0,
   struct _fx_LN14C_form__cexp_t_data_t* t1,
   struct _fx_T2iLN14C_form__cexp_t* fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void
   _fx_free_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      dst)
{
   _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
   _fx_free_LN15C_form__cstmt_t(&dst->t3);
}

static void
   _fx_copy_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      src,
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void
   _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   bool t0,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_LN15C_form__cstmt_t_data_t* t3,
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t*
      fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void
   _fx_free_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t*
      dst)
{
   _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void
   _fx_copy_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t*
      src,
   struct _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t*
      dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void
   _fx_make_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t*
      fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

static void
   _fx_free_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t(
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t*
      dst)
{
   _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
   _fx_free_Ta2LN15C_form__cstmt_t(&dst->t3);
}

static void
   _fx_copy_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t(
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t*
      src,
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t*
      dst)
{
   dst->t0 = src->t0;
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   _fx_copy_Ta2LN15C_form__cstmt_t(&src->t3, &dst->t3);
}

static void
   _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t(
   bool t0,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_Ta2LN15C_form__cstmt_t* t3,
   struct _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t*
      fx_result)
{
   fx_result->t0 = t0;
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   _fx_copy_Ta2LN15C_form__cstmt_t(t3, &fx_result->t3);
}

static void _fx_free_Ta2Nt6option1N14C_form__ctyp_t(struct _fx_Ta2Nt6option1N14C_form__ctyp_t* dst)
{
   _fx_free_Nt6option1N14C_form__ctyp_t(&dst->t0);
   _fx_free_Nt6option1N14C_form__ctyp_t(&dst->t1);
}

static void _fx_copy_Ta2Nt6option1N14C_form__ctyp_t(
   struct _fx_Ta2Nt6option1N14C_form__ctyp_t* src,
   struct _fx_Ta2Nt6option1N14C_form__ctyp_t* dst)
{
   _fx_copy_Nt6option1N14C_form__ctyp_t(&src->t0, &dst->t0);
   _fx_copy_Nt6option1N14C_form__ctyp_t(&src->t1, &dst->t1);
}

static void _fx_make_Ta2Nt6option1N14C_form__ctyp_t(
   struct _fx_Nt6option1N14C_form__ctyp_t* t0,
   struct _fx_Nt6option1N14C_form__ctyp_t* t1,
   struct _fx_Ta2Nt6option1N14C_form__ctyp_t* fx_result)
{
   _fx_copy_Nt6option1N14C_form__ctyp_t(t0, &fx_result->t0);
   _fx_copy_Nt6option1N14C_form__ctyp_t(t1, &fx_result->t1);
}

static void _fx_free_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* dst)
{
   _fx_free_R17K_form__kmodule_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
   _fx_free_LN15C_form__cstmt_t(&dst->t2);
   _fx_free_LN15C_form__cstmt_t(&dst->t3);
}

static void _fx_copy_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* src,
   struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* dst)
{
   _fx_copy_R17K_form__kmodule_t(&src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
   FX_COPY_PTR(src->t2, &dst->t2);
   FX_COPY_PTR(src->t3, &dst->t3);
}

static void _fx_make_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_R17K_form__kmodule_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_LN15C_form__cstmt_t_data_t* t2,
   struct _fx_LN15C_form__cstmt_t_data_t* t3,
   struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* fx_result)
{
   _fx_copy_R17K_form__kmodule_t(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
   FX_COPY_PTR(t2, &fx_result->t2);
   FX_COPY_PTR(t3, &fx_result->t3);
}

static void _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t** dst)
{
   FX_FREE_LIST_IMPL(_fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t,
      _fx_free_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t);
}

static int _fx_cons_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* hd,
   struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t* tl,
   bool addref_tl,
   struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t** fx_result)
{
   FX_MAKE_LIST_IMPL(_fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t,
      _fx_copy_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t);
}

static void _fx_free_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* dst)
{
   _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&dst->t0);
   _fx_free_LN15C_form__cstmt_t(&dst->t1);
}

static void _fx_copy_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* src,
   struct _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* dst)
{
   FX_COPY_PTR(src->t0, &dst->t0);
   FX_COPY_PTR(src->t1, &dst->t1);
}

static void _fx_make_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t_data_t* t0,
   struct _fx_LN15C_form__cstmt_t_data_t* t1,
   struct _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* fx_result)
{
   FX_COPY_PTR(t0, &fx_result->t0);
   FX_COPY_PTR(t1, &fx_result->t1);
}

_fx_Nt6option1rR23C_gen_code__block_ctx_t _fx_g16C_gen_code__None = { 1 };
_fx_Nt6option1N14C_form__ctyp_t _fx_g18C_gen_code__None1_ = { 1 };
_fx_Nt6option1N14C_form__cexp_t _fx_g18C_gen_code__None2_ = { 1 };
_fx_Nt6option1R9Ast__id_t _fx_g18C_gen_code__None3_ = { 1 };
_fx_Nt6option1i _fx_g18C_gen_code__None4_ = { 1 };
_fx_N12Ast__cmpop_t _fx_g17C_gen_code__CmpEQ = { 1 };
_fx_N12Ast__cmpop_t _fx_g17C_gen_code__CmpNE = { 2 };
_fx_N12Ast__cmpop_t _fx_g17C_gen_code__CmpLT = { 3 };
_fx_N12Ast__cmpop_t _fx_g17C_gen_code__CmpLE = { 4 };
_fx_N12Ast__cmpop_t _fx_g17C_gen_code__CmpGE = { 5 };
_fx_N12Ast__cmpop_t _fx_g17C_gen_code__CmpGT = { 6 };
_fx_N17C_form__cbinary_t _fx_g18C_gen_code__COpAdd = { 1 };
_fx_N17C_form__cbinary_t _fx_g18C_gen_code__COpSub = { 2 };
_fx_N17C_form__cbinary_t _fx_g18C_gen_code__COpMul = { 3 };
_fx_N17C_form__cbinary_t _fx_g18C_gen_code__COpDiv = { 4 };
_fx_N17C_form__cbinary_t _fx_g18C_gen_code__COpMod = { 5 };
_fx_N17C_form__cbinary_t _fx_g24C_gen_code__COpShiftLeft = { 6 };
_fx_N17C_form__cbinary_t _fx_g25C_gen_code__COpShiftRight = { 7 };
_fx_N17C_form__cbinary_t _fx_g25C_gen_code__COpBitwiseAnd = { 8 };
_fx_N17C_form__cbinary_t _fx_g24C_gen_code__COpBitwiseOr = { 9 };
_fx_N17C_form__cbinary_t _fx_g25C_gen_code__COpBitwiseXor = { 10 };
_fx_N17C_form__cbinary_t _fx_g23C_gen_code__COpLogicAnd = { 11 };
_fx_N17C_form__cbinary_t _fx_g22C_gen_code__COpLogicOr = { 12 };
_fx_N17C_form__cbinary_t _fx_g24C_gen_code__COpArrayElem = { 14 };
_fx_N17C_form__cbinary_t _fx_g21C_gen_code__COpAssign = { 15 };
_fx_N17C_form__cbinary_t _fx_g21C_gen_code__COpAugAdd = { 16 };
_fx_N16C_form__cunary_t _fx_g19C_gen_code__COpPlus = { 1 };
_fx_N16C_form__cunary_t _fx_g21C_gen_code__COpNegate = { 2 };
_fx_N16C_form__cunary_t _fx_g25C_gen_code__COpBitwiseNot = { 3 };
_fx_N16C_form__cunary_t _fx_g23C_gen_code__COpLogicNot = { 4 };
_fx_N16C_form__cunary_t _fx_g20C_gen_code__COpDeref = { 5 };
_fx_N16C_form__cunary_t _fx_g24C_gen_code__COpSuffixInc = { 9 };
_fx_N19C_form__ctyp_attr_t _fx_g21C_gen_code__CTypConst = { 1 };
_fx_N19C_form__carg_attr_t _fx_g25C_gen_code__CArgPassByPtr = { 1 };
static _fx_N14C_form__ctyp_t_data_t CTypInt_data_4 = { 1, 1 };
_fx_N14C_form__ctyp_t _fx_g19C_gen_code__CTypInt = &CTypInt_data_4;
static _fx_N14C_form__ctyp_t_data_t CTypCInt_data_4 = { 1, 2 };
_fx_N14C_form__ctyp_t _fx_g20C_gen_code__CTypCInt = &CTypCInt_data_4;
static _fx_N14C_form__ctyp_t_data_t CTypSize_t_data_1 = { 1, 3 };
_fx_N14C_form__ctyp_t _fx_g22C_gen_code__CTypSize_t = &CTypSize_t_data_1;
static _fx_N14C_form__ctyp_t_data_t CTypVoid_data_4 = { 1, 8 };
_fx_N14C_form__ctyp_t _fx_g20C_gen_code__CTypVoid = &CTypVoid_data_4;
static _fx_N14C_form__ctyp_t_data_t CTypBool_data_3 = { 1, 9 };
_fx_N14C_form__ctyp_t _fx_g20C_gen_code__CTypBool = &CTypBool_data_3;
static _fx_N14C_form__ctyp_t_data_t CTypUniChar_data_2 = { 1, 10 };
_fx_N14C_form__ctyp_t _fx_g23C_gen_code__CTypUniChar = &CTypUniChar_data_2;
static _fx_N14C_form__ctyp_t_data_t CTypString_data_4 = { 1, 12 };
_fx_N14C_form__ctyp_t _fx_g22C_gen_code__CTypString = &CTypString_data_4;
static _fx_N14C_form__ctyp_t_data_t CTypExn_data_4 = { 1, 13 };
_fx_N14C_form__ctyp_t _fx_g19C_gen_code__CTypExn = &CTypExn_data_4;
static _fx_N14C_form__ctyp_t_data_t CTypAny_data_3 = { 1, 23 };
_fx_N14C_form__ctyp_t _fx_g19C_gen_code__CTypAny = &CTypAny_data_3;
_fx_N24C_gen_code__block_kind_t _fx_g28C_gen_code__BlockKind_Global = { 1 };
_fx_N24C_gen_code__block_kind_t _fx_g27C_gen_code__BlockKind_Block = { 3 };
_fx_N24C_gen_code__block_kind_t _fx_g25C_gen_code__BlockKind_Try = { 4 };
_fx_N24C_gen_code__block_kind_t _fx_g26C_gen_code__BlockKind_Loop = { 5 };
_fx_N24C_gen_code__block_kind_t _fx_g28C_gen_code__BlockKind_LoopND = { 6 };
_fx_N24C_gen_code__block_kind_t _fx_g26C_gen_code__BlockKind_Case = { 7 };
FX_EXTERN_C int _fx_M3AstFM6__eq__B2RM4id_tRM4id_t(
   struct _fx_R9Ast__id_t* a_0,
   struct _fx_R9Ast__id_t* b_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_F4reprS1S(fx_str_t* a_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM6stringS1RM4id_t(struct _fx_R9Ast__id_t* i_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_F12join_embraceS4SSSA1S(
   fx_str_t* begin,
   fx_str_t* end,
   fx_str_t* sep,
   fx_arr_t* strs,
   fx_str_t* fx_result,
   void* fx_fv);

FX_EXTERN_C bool _fx_M10C_gen_codeFM8__same__B2LN14C_form__ctyp_tLN14C_form__ctyp_t(
   struct _fx_LN14C_form__ctyp_t_data_t* a,
   struct _fx_LN14C_form__ctyp_t_data_t* b,
   void* fx_fv);

FX_EXTERN_C int _fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* a_0,
   struct _fx_N14C_form__ctyp_t_data_t* b_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C bool _fx_M10C_gen_codeFM8__same__B2LT2R9Ast__id_tN14C_form__ctyp_tLT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* a,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* b,
   void* fx_fv);

FX_EXTERN_C int _fx_M10C_gen_codeFM6__eq__B2T2R9Ast__id_tN14C_form__ctyp_tT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* a_0,
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* b_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C bool _fx_M10C_gen_codeFM8__same__B2LN19C_form__ctyp_attr_tLN19C_form__ctyp_attr_t(
   struct _fx_LN19C_form__ctyp_attr_t_data_t* a,
   struct _fx_LN19C_form__ctyp_attr_t_data_t* b,
   void* fx_fv);

FX_EXTERN_C int _fx_M7HashmapFM9makeindexA1i1i(int_ size_0, fx_arr_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_F9make_FailE1S(fx_str_t* arg0, fx_exn_t* fx_result);

FX_EXTERN_C int _fx_F6assertv1B(bool f_0, void* fx_fv);

FX_EXTERN_C int _fx_M7HashsetFM9makeindexA1i1i(int_ size_0, fx_arr_t* fx_result, void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g9Ast__noid)
FX_EXTERN_C int _fx_M3AstFM16empty_id_hashsetNt10Hashset__t1RM4id_t1i(
   int_ size0_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t2rNt10Hashmap__t2R9Ast__id_tirNt10Hashset__t1R9Ast__id_t(
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t* fx_result);

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPv2N14K_form__kexp_tR22K_form__k_fold_callb_t2rNt10Hashmap__t2R9Ast__id_tirNt10Hashset__t1R9Ast__id_t(
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t* fx_result);

static int _fx_M10C_gen_codeFM10__lambda__v3R9Ast__id_trNt10Hashmap__t2R9Ast__id_tiNt10Hashset__t1R9Ast__id_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* count_map_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1_vals_0,
   void* fx_fv);

static int _fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv);

static int _fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM8get_kvalRM9kdefval_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R17K_form__kdefval_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M15K_remove_unusedFM9pure_kexpB1N14K_form__kexp_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C void _fx_M6K_formFM6AtomIdN14K_form__atom_t1R9Ast__id_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_N14K_form__atom_t* fx_result);

FX_EXTERN_C int _fx_M6K_formFM9fold_kexpv2N14K_form__kexp_tRM14k_fold_callb_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M10C_gen_codeFM7make_fpFPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t2R9Ast__id_trB(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_rB_data_t* arg1,
   struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t* fx_result);

FX_EXTERN_C int _fx_M10C_gen_codeFM7make_fpFPv2N14K_form__kexp_tR22K_form__k_fold_callb_t1rB(
   struct _fx_rB_data_t* arg0,
   struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t* fx_result);

FX_EXTERN_C int _fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N15K_form__kinfo_t* fx_result,
   void* fx_fv);

static int _fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv);

static int _fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM9CExpCCodeN14C_form__cexp_t2SR10Ast__loc_t(
   fx_str_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* arg0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_F4joinS2SLS(fx_str_t* sep_0, struct _fx_LS_data_t* strs_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM12get_cexp_ctxT2N14C_form__ctyp_tR10Ast__loc_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM9try_derefT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* cexp_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_R10Ast__loc_t* cloc_0,
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N15C_form__cinfo_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM13get_idc_cnameS2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_R10Ast__loc_t* loc_0,
   fx_str_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM11compile_errE2RM5loc_tS(
   struct _fx_R10Ast__loc_t* loc_0,
   fx_str_t* msg_0,
   fx_exn_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM13get_cstmt_locR10Ast__loc_t1N15C_form__cstmt_t(
   struct _fx_N15C_form__cstmt_t_data_t* s_0,
   struct _fx_R10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C void _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(
   struct _fx_N12Ast__cmpop_t* arg0,
   struct _fx_N17C_form__cbinary_t* fx_result);

FX_EXTERN_C int
   _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N17C_form__cbinary_t* arg0,
   struct _fx_N14C_form__cexp_t_data_t* arg1,
   struct _fx_N14C_form__cexp_t_data_t* arg2,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* arg3,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N16C_form__cunary_t* arg0,
   struct _fx_N14C_form__cexp_t_data_t* arg1,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* arg2,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM8CStmtNopN15C_form__cstmt_t1R10Ast__loc_t(
   struct _fx_R10Ast__loc_t* arg0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM7CStmtIfN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* arg0,
   struct _fx_N15C_form__cstmt_t_data_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t* arg2,
   struct _fx_R10Ast__loc_t* arg3,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R17C_form__ctprops_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_R10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M10K_annotateFM11get_ktpropsR17K_form__ktprops_t2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__ktyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R17K_form__ktprops_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(
   int_ i_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(
   struct _fx_LN19C_form__ctyp_attr_t_data_t* arg0,
   struct _fx_N14C_form__ctyp_t_data_t* arg1,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_LN14C_form__cexp_t_data_t* arg0,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* arg1,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(struct _fx_R16Ast__val_flags_t* fx_result, void* fx_fv);

FX_EXTERN_C int
   _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_R16Ast__val_flags_t* flags_0,
   fx_str_t* cname_0,
   struct _fx_Nt6option1N14C_form__cexp_t* e_opt_0,
   struct _fx_LN15C_form__cstmt_t_data_t* code_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g18C_form__std_sizeof)
FX_EXTERN_C int _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* f_0,
   struct _fx_LN14C_form__cexp_t_data_t* args_0,
   struct _fx_N14C_form__ctyp_t_data_t* rt_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M11C_gen_typesFM10get_free_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   bool let_none_0,
   bool let_macro_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2BNt6option1N14C_form__cexp_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_N14C_form__ctyp_t_data_t* _fx_g21C_form__std_fx_free_t)
FX_EXTERN_C int _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* arg0,
   struct _fx_N14C_form__ctyp_t_data_t* arg1,
   struct _fx_R10Ast__loc_t* arg2,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M11C_gen_typesFM10get_copy_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   bool let_none_0,
   bool let_macro_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2BNt6option1N14C_form__cexp_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_N14C_form__ctyp_t_data_t* _fx_g21C_form__std_fx_copy_t)
FX_EXTERN_C int _fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_F6stringS1i(int_ a, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g28C_form__std_FX_CHECK_EQ_SIZE)
FX_EXTERN_C int _fx_M6StringFM10num_suffixS1i(int_ n_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM12get_idk_ktypN14K_form__ktyp_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14K_form__ktyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C void _fx_M3AstFM8ScModuleN12Ast__scope_t1i(int_ arg0, struct _fx_N12Ast__scope_t* fx_result);

FX_EXTERN_C_VAL(struct _fx_R10Ast__loc_t _fx_g10Ast__noloc)
FX_EXTERN_C int _fx_M3AstFM6get_idRM4id_t1S(fx_str_t* s_0, struct _fx_R9Ast__id_t* fx_result, void* fx_fv);

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t*
      fx_result);

static int _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
   struct _fx_N24C_gen_code__block_kind_t* kind_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   int_ km_idx_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM7gen_idcR9Ast__id_t2iS(
   int_ m_idx_0,
   fx_str_t* s_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(struct _fx_R16Ast__val_flags_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM9code2kexpN14K_form__kexp_t2LN14K_form__kexp_tR10Ast__loc_t(
   struct _fx_LN14K_form__kexp_t_data_t* code_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14K_form__kexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM2ppS1RM4id_t(struct _fx_R9Ast__id_t* i_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM10pr_verbosev1S(fx_str_t* str_0, void* fx_fv);

static int _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rR23C_gen_code__block_ctx_t_data_t** fx_result,
   void* fx_fv);

static int _fx_M10C_gen_codeFM13pop_block_ctxv2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM9cexp2stmtN15C_form__cstmt_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM15filter_out_nopsLN15C_form__cstmt_t1LN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* code_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_Nt6option1N14C_form__cexp_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M8K_mangleFM12mangle_mnameS1S(fx_str_t* m_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM17default_fun_flagsRM11fun_flags_t0(struct _fx_R16Ast__fun_flags_t* fx_result, void* fx_fv);

FX_EXTERN_C void _fx_M6C_formFM4CFunN15C_form__cinfo_t1rRM9cdeffun_t(
   struct _fx_rR17C_form__cdeffun_t_data_t* arg0,
   struct _fx_N15C_form__cinfo_t* fx_result);

FX_EXTERN_C int _fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_N15C_form__cinfo_t* entry_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM7CDefFunN15C_form__cstmt_t1rRM9cdeffun_t(
   struct _fx_rR17C_form__cdeffun_t_data_t* arg0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM14CDefForwardSymN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

static int _fx_M10C_gen_codeFM18check_inside_loop_v4LrRM11block_ctx_tSBR10Ast__loc_t(
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t* s_0,
   fx_str_t* bc_str_0,
   bool is_break_0,
   struct _fx_R10Ast__loc_t* loc_0,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C bool _fx_M6StringFM10startswithB2SS(fx_str_t* s, fx_str_t* prefix, void* fx_fv);

FX_EXTERN_C bool _fx_F6__eq__B2SS(fx_str_t* a, fx_str_t* b, void* fx_fv);

FX_EXTERN_C void _fx_M6C_formFM6CLabelN15C_form__cinfo_t1RM11cdeflabel_t(
   struct _fx_R19C_form__cdeflabel_t* arg0,
   struct _fx_N15C_form__cinfo_t* fx_result);

FX_EXTERN_C int _fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM17default_for_flagsRM11for_flags_t0(struct _fx_R16Ast__for_flags_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g19C_form__std_FX_CALL)
FX_EXTERN_C int
   _fx_M11C_gen_typesFM13gen_free_codeLN15C_form__cstmt_t6N14C_form__cexp_tN14C_form__ctyp_tBBLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* elem_exp_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   bool let_macro_0,
   bool use_if_0,
   struct _fx_LN15C_form__cstmt_t_data_t* code_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int
   _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* src_exp_0,
   struct _fx_N14C_form__cexp_t_data_t* dst_exp_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_LN15C_form__cstmt_t_data_t* code_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g20C_form__std_FX_BREAK)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g23C_form__std_FX_CONTINUE)
FX_EXTERN_C int _fx_M6C_formFM7dup_idcR9Ast__id_t2iR9Ast__id_t(
   int_ m_idx_0,
   struct _fx_R9Ast__id_t* old_id_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM10CTypRawPtrN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(
   struct _fx_LN19C_form__ctyp_attr_t_data_t* arg0,
   struct _fx_N14C_form__ctyp_t_data_t* arg1,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6K_formFM13is_val_globalB1R16Ast__val_flags_t(
   struct _fx_R16Ast__val_flags_t* flags_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g29C_form__std_FX_CHECK_CONTINUE)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g26C_form__std_FX_CHECK_BREAK)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g29C_form__std_FX_CHECK_BREAK_ND)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g24C_form__std_FX_CHECK_EXN)
FX_EXTERN_C int _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_LN15C_form__cstmt_t_data_t* code_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* a_0,
   bool save_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM12make_lit_expN14C_form__cexp_t2N14K_form__klit_tR10Ast__loc_t(
   struct _fx_N14K_form__klit_t* l_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g23C_form__std_FX_MAKE_STR)
FX_EXTERN_C int _fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__ktyp_t_data_t* kt_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14K_form__ktyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(
   struct _fx_N14K_form__ktyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM10CTypVectorN14C_form__ctyp_t1N14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* arg0,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM9CTypArrayN14C_form__ctyp_t2iN14C_form__ctyp_t(
   int_ arg0,
   struct _fx_N14C_form__ctyp_t_data_t* arg1,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6K_formFM6stringS1N14K_form__ktyp_t(
   struct _fx_N14K_form__ktyp_t_data_t* t_0,
   fx_str_t* fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g23C_form__std_fx_make_arr)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g23C_form__std_fx_make_vec)
FX_EXTERN_C int _fx_M11C_gen_typesFM15get_constructorR9Ast__id_t3N14C_form__ctyp_tBR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   bool required_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM13make_bool_expN14C_form__cexp_t2BR10Ast__loc_t(
   bool b_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_N14C_form__cexp_t_data_t* lbl_0,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* idoml_0,
   struct _fx_LR9Ast__id_t_data_t* at_ids_0,
   int_ for_idx_0,
   int_ nfors_0,
   int_ ndims_0,
   int_ dims_ofs_0,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* nested_e_idoml_0,
   struct _fx_LN15C_form__cstmt_t_data_t* init_ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*
      fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM13get_start_locRM5loc_t1RM5loc_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C void _fx_M6K_formFM7KLitIntN14K_form__klit_t1l(int64_t arg0, struct _fx_N14K_form__klit_t* fx_result);

FX_EXTERN_C void _fx_M6K_formFM7AtomLitN14K_form__atom_t1N14K_form__klit_t(
   struct _fx_N14K_form__klit_t* arg0,
   struct _fx_N14K_form__atom_t* fx_result);

FX_EXTERN_C_VAL(struct _fx_N14K_form__atom_t _fx_g17K_form___ALitVoid)
FX_EXTERN_C void _fx_M6K_formFM11DomainRangeN13K_form__dom_t3N14K_form__atom_tN14K_form__atom_tN14K_form__atom_t(
   struct _fx_N14K_form__atom_t* arg0,
   struct _fx_N14K_form__atom_t* arg1,
   struct _fx_N14K_form__atom_t* arg2,
   struct _fx_N13K_form__dom_t* fx_result);

FX_EXTERN_C int _fx_M6C_formFM13make_int__expN14C_form__cexp_t2lR10Ast__loc_t(
   int64_t i_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g30C_form__std_FX_CHECK_ZERO_STEP)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g25C_form__std_FX_LOOP_COUNT)
static int _fx_M10C_gen_codeFM11get_iter_idR9Ast__id_t7iLR9Ast__id_tSiiR10Ast__loc_ti(
   int_ k_0,
   struct _fx_LR9Ast__id_t_data_t* at_ids_0,
   fx_str_t* prefix_0,
   int_ for_idx_0,
   int_ km_idx_0,
   struct _fx_R10Ast__loc_t* loc_0,
   int_ nfors_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14K_form__ktyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_R9Ast__id_t* m_id_0,
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM11make_assignN14C_form__cexp_t2N14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* lhs_0,
   struct _fx_N14C_form__cexp_t_data_t* rhs_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM14is_ktyp_scalarB1N14K_form__ktyp_t(
   struct _fx_N14K_form__ktyp_t_data_t* ktyp_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM21default_tempref_flagsRM11val_flags_t0(struct _fx_R16Ast__val_flags_t* fx_result, void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g25C_form__std_FX_STR_LENGTH)
FX_EXTERN_C int _fx_M6C_formFM14make_const_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_R9Ast__id_t* m_id_0,
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g23C_form__std_FX_ARR_SIZE)
FX_EXTERN_C_VAL(struct _fx_LR9Ast__id_t_data_t* _fx_g21C_form__std_FX_PTR_xD)
FX_EXTERN_C int _fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C_VAL(struct _fx_N14C_form__ctyp_t_data_t* _fx_g23C_form__std_CTypVoidPtr)
FX_EXTERN_C int _fx_M6K_formFM8atom2strS1N14K_form__atom_t(struct _fx_N14K_form__atom_t* a_0, fx_str_t* fx_result, void* fx_fv);

static int
   _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t* cases_0,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   bool is_catch_case_0,
   struct _fx_R10Ast__loc_t* kloc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM9CStmtGotoN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g25C_form__std_FX_FAST_THROW)
FX_EXTERN_C int _fx_M6C_formFM10stmt2ccodeLN15C_form__cstmt_t1N15C_form__cstmt_t(
   struct _fx_N15C_form__cstmt_t_data_t* s_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_N14K_form__kexp_t_data_t* kexp_0,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM12get_kexp_ctxT2N14K_form__ktyp_tR10Ast__loc_t1N14K_form__kexp_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_T2N14K_form__ktyp_tR10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM15is_ktyp_integerB2N14K_form__ktyp_tB(
   struct _fx_N14K_form__ktyp_t_data_t* t_0,
   bool allow_bool_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(int_ arg0, struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M3AstFM6stringS1N13Ast__binary_t(
   struct _fx_N13Ast__binary_t_data_t* bop_0,
   fx_str_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM6stringS1N12Ast__unary_t(struct _fx_N12Ast__unary_t* uop_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g30C_form__std_FX_REC_VARIANT_TAG)
FX_EXTERN_C int _fx_M6C_formFM7CExpLitN14C_form__cexp_t2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14K_form__klit_t* arg0,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* arg1,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_F6stringS1B(bool a_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   fx_str_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM11get_orig_idRM4id_t1RM4id_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM18get_cinterface_optNt6option1rRM15cdefinterface_t2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_Nt6option1rR23C_form__cdefinterface_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g26C_form__std_fx_query_iface)
FX_EXTERN_C int _fx_M3AstFM14same_or_parentB3RM4id_tRM4id_tRM5loc_t(
   struct _fx_R9Ast__id_t* iface_0,
   struct _fx_R9Ast__id_t* maybe_parent_0,
   struct _fx_R10Ast__loc_t* loc_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2SR9Ast__id_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g25C_form__std_fx_make_iface)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g25C_form__std_fx_get_object)
FX_EXTERN_C int _fx_F6stringS1C(char_ c, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C void _fx_M6K_formFM10KLitStringN14K_form__klit_t1S(fx_str_t* arg0, struct _fx_N14K_form__klit_t* fx_result);

FX_EXTERN_C int _fx_F6stringS1l(int64_t a, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g29C_form__std_FX_MAKE_FP_BY_FCV)
static int _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
   struct _fx_N14K_form__atom_t* range_idx_0,
   int64_t deflt_0,
   struct _fx_N14K_form__atom_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M3AstFM6stringS1N13Ast__intrin_t(struct _fx_N13Ast__intrin_t* iop_0, fx_str_t* fx_result, void* fx_fv);

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t*
      fx_result);

FX_EXTERN_C int _fx_M6C_formFM9CStmtSyncN15C_form__cstmt_t2R9Ast__id_tN15C_form__cstmt_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_N15C_form__cstmt_t_data_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM7idc2strS2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   fx_str_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM8CExpCallN14C_form__cexp_t3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* arg0,
   struct _fx_LN14C_form__cexp_t_data_t* arg1,
   struct _fx_T2N14C_form__ctyp_tR10Ast__loc_t* arg2,
   struct _fx_N14C_form__cexp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM8CTypSIntN14C_form__ctyp_t1i(int_ arg0, struct _fx_N14C_form__ctyp_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM8get_cvalRM9cdefval_t2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R17C_form__cdefval_t* fx_result,
   void* fx_fv);

FX_EXTERN_C void _fx_M6C_formFM4CValN15C_form__cinfo_t1RM9cdefval_t(
   struct _fx_R17C_form__cdefval_t* arg0,
   struct _fx_N15C_form__cinfo_t* fx_result);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g23C_form__std_FX_STR_ELEM)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g25C_form__std_FX_STR_CHKIDX)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g28C_form__std_FX_STR_ELEM_CLIP)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g28C_form__std_FX_STR_ELEM_WRAP)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g28C_form__std_FX_STR_ELEM_ZERO)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g21C_form__std_fx_substr)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g21C_form__std_fx_subarr)
FX_EXTERN_C void _fx_M6K_formFM10DomainFastN13K_form__dom_t1N14K_form__atom_t(
   struct _fx_N14K_form__atom_t* arg0,
   struct _fx_N13K_form__dom_t* fx_result);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g22C_form__std_FX_CHKIDX1)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g21C_form__std_FX_CHKIDX)
FX_EXTERN_C_VAL(struct _fx_LR9Ast__id_t_data_t* _fx_g26C_form__std_FX_PTR_xD_CLIP)
FX_EXTERN_C_VAL(struct _fx_LR9Ast__id_t_data_t* _fx_g26C_form__std_FX_PTR_xD_WRAP)
FX_EXTERN_C_VAL(struct _fx_LR9Ast__id_t_data_t* _fx_g26C_form__std_FX_PTR_xD_ZERO)
FX_EXTERN_C int _fx_M6K_formFM11is_subarrayB2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g28C_form__std_fx_copy_arr_data)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g22C_form__std_FX_RETHROW)
FX_EXTERN_C_VAL(struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t _fx_g23Ast__builtin_exceptions)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g20C_form__std_FX_THROW)
FX_EXTERN_C int _fx_M6K_formFM8declaredNt10Hashset__t1R9Ast__id_t2LN14K_form__kexp_ti(
   struct _fx_LN14K_form__kexp_t_data_t* code_0,
   int_ size0_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t** fx_result,
   void* fx_fv);

static int _fx_M10C_gen_codeFM16check_range_elemB3N14K_form__atom_tNt10Hashset__t1R9Ast__id_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* abd_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* decl_inside_for_0,
   struct _fx_R10Ast__loc_t* kloc_0,
   bool* fx_result,
   void* fx_fv);

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrR23C_gen_code__block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB*
      fx_result);

FX_EXTERN_C int
   _fx_M6C_formFM8CStmtForN15C_form__cstmt_t6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_Nt6option1N14C_form__ctyp_t* arg0,
   struct _fx_LN14C_form__cexp_t_data_t* arg1,
   struct _fx_Nt6option1N14C_form__cexp_t* arg2,
   struct _fx_LN14C_form__cexp_t_data_t* arg3,
   struct _fx_N15C_form__cstmt_t_data_t* arg4,
   struct _fx_R10Ast__loc_t* arg5,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM12CMacroPragmaN15C_form__cstmt_t2SR10Ast__loc_t(
   fx_str_t* arg0,
   struct _fx_R10Ast__loc_t* arg1,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM10CStmtWhileN15C_form__cstmt_t3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* arg0,
   struct _fx_N15C_form__cstmt_t_data_t* arg1,
   struct _fx_R10Ast__loc_t* arg2,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6C_formFM12CStmtDoWhileN15C_form__cstmt_t3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
   struct _fx_N15C_form__cstmt_t_data_t* arg0,
   struct _fx_N14C_form__cexp_t_data_t* arg1,
   struct _fx_R10Ast__loc_t* arg2,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M3AstFM17default_val_flagsRM11val_flags_t0(struct _fx_R16Ast__val_flags_t* fx_result, void* fx_fv);

FX_EXTERN_C int _fx_M6C_formFM7CDefValN15C_form__cstmt_t4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* arg0,
   struct _fx_R9Ast__id_t* arg1,
   struct _fx_Nt6option1N14C_form__cexp_t* arg2,
   struct _fx_R10Ast__loc_t* arg3,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result);

FX_EXTERN_C int _fx_M6K_formFM12get_kexp_endR10Ast__loc_t1N14K_form__kexp_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R10Ast__loc_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g48C_form__std_FX_MAKE_RECURSIVE_VARIANT_IMPL_START)
FX_EXTERN_C int _fx_M6K_formFM13get_idk_cnameS2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   fx_str_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g33C_form__std_FX_MAKE_FP_IMPL_START)
FX_EXTERN_C_VAL(struct _fx_N14C_form__ctyp_t_data_t* _fx_g25C_form__std_fx_exn_info_t)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g34C_form__std_FX_MAKE_EXN_IMPL_START)
FX_EXTERN_C int _fx_M3AstFM8ctor2strS1N17Ast__fun_constr_t(
   struct _fx_N17Ast__fun_constr_t* f_0,
   fx_str_t* fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_LN14K_form__kexp_t_data_t* el_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   struct _fx_N14C_form__cexp_t_data_t* dummy_exp_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M6K_formFM10is_mutableB2R9Ast__id_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* n_0,
   struct _fx_R10Ast__loc_t* loc_0,
   bool* fx_result,
   void* fx_fv);

static int
   _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB(
   struct _fx_LN15C_form__cstmt_t_data_t* pre_map_ccode_0,
   int_ for_idx_0,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* e_idoml_l_0,
   struct _fx_LN14C_form__cexp_t_data_t* prev_i_exps_0,
   struct _fx_LN14C_form__cexp_t_data_t* prev_n_exps_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_LN15C_form__cstmt_t_data_t* decl_nested_status_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* dst_data_0,
   struct _fx_R10Ast__loc_t* end_for_loc_0,
   struct _fx_N15Ast__for_make_t* for_flag_make_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_R10Ast__loc_t* for_loc_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   bool is_parallel_map_0,
   struct _fx_R10Ast__loc_t* kloc_0,
   int_ km_idx_0,
   struct _fx_N14C_form__cexp_t_data_t* map_lbl_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   int_ ndims_0,
   bool need_make_array_0,
   struct _fx_N14C_form__cexp_t_data_t* nested_status_0,
   int_ nfors_0,
   struct _fx_N14C_form__cexp_t_data_t* par_status_0,
   bool pre_alloc_array_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   bool unzip_mode_0,
   struct _fx_Ta2LN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g26C_form__std_fx_list_length)
FX_EXTERN_C_VAL(struct _fx_R9Ast__id_t _fx_g26C_form__std_FX_LIST_APPEND)
FX_EXTERN_C int _fx_M11C_gen_typesFM16convert_all_typsTa3LN15C_form__cstmt_t1LR17K_form__kmodule_t(
   struct _fx_LR17K_form__kmodule_t_data_t* kmods_0,
   struct _fx_Ta3LN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int _fx_M12C_gen_fdeclsFM18convert_all_fdeclsTa3LN15C_form__cstmt_t2iLN14K_form__kexp_t(
   int_ cm_idx_0,
   struct _fx_LN14K_form__kexp_t_data_t* top_code_0,
   struct _fx_Ta3LN15C_form__cstmt_t* fx_result,
   void* fx_fv);

FX_EXTERN_C int
   _fx_M11C_gen_typesFM18elim_unused_ctypesLN15C_form__cstmt_t5R9Ast__id_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_R9Ast__id_t* mname_0,
   struct _fx_LN15C_form__cstmt_t_data_t* all_ctypes_fwd_decl_0,
   struct _fx_LN15C_form__cstmt_t_data_t* all_ctypes_decl_0,
   struct _fx_LN15C_form__cstmt_t_data_t* all_ctypes_fun_decl_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv);

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
} _fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t;

FX_EXTERN_C void _fx_free_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   _fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t* dst)
{
   _fx_free_rNt10Hashmap__t2R9Ast__id_ti(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
} _fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t;

FX_EXTERN_C void _fx_free_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   _fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t* dst)
{
   _fx_free_rNt10Hashmap__t2R9Ast__id_ti(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_R9Ast__id_t t0;
   struct _fx_rB_data_t* t1;
} _fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t;

FX_EXTERN_C void _fx_free_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   _fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t* dst)
{
   FX_FREE_REF_SIMPLE(&dst->t1);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rB_data_t* t0;
} _fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t;

FX_EXTERN_C void _fx_free_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   _fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t* dst)
{
   FX_FREE_REF_SIMPLE(&dst->t0);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t(
   _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

typedef struct {
   int_ rc;
   fx_free_t free_f;
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* t0;
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* t1;
   struct _fx_rLN15C_form__cstmt_t_data_t* t2;
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* t3;
   int_ t4;
} _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB_cldata_t;

FX_EXTERN_C void
   _fx_free_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB(
   _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB_cldata_t*
      dst)
{
   _fx_free_rLrR23C_gen_code__block_ctx_t(&dst->t0);
   _fx_free_rNt10Hashset__t1R9Ast__id_t(&dst->t1);
   _fx_free_rLN15C_form__cstmt_t(&dst->t2);
   _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&dst->t3);
   fx_free(dst);
}

FX_EXTERN_C void _fx_M10C_gen_codeFM4SomeNt6option1rRM11block_ctx_t1rRM11block_ctx_t(
   struct _fx_rR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_Nt6option1rR23C_gen_code__block_ctx_t* fx_result)
{
   fx_result->tag = 2;
   FX_COPY_PTR(arg0, &fx_result->u.Some);
}

FX_EXTERN_C void _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__ctyp_t1N14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* arg0,
   struct _fx_Nt6option1N14C_form__ctyp_t* fx_result)
{
   fx_result->tag = 2;
   FX_COPY_PTR(arg0, &fx_result->u.Some);
}

FX_EXTERN_C void _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* arg0,
   struct _fx_Nt6option1N14C_form__cexp_t* fx_result)
{
   fx_result->tag = 2;
   FX_COPY_PTR(arg0, &fx_result->u.Some);
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM4SomeNt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t* arg0,
   struct _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t** fx_result)
{
   FX_MAKE_RECURSIVE_VARIANT_IMPL_START(_fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t);
   FX_COPY_FP(arg0, &v->u.Some);
   return 0;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM4SomeNt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t* arg0,
   struct _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t_data_t** fx_result)
{
   FX_MAKE_RECURSIVE_VARIANT_IMPL_START(_fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t);
   FX_COPY_FP(arg0, &v->u.Some);
   return 0;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM4SomeNt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t* arg0,
   struct _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t_data_t** fx_result)
{
   FX_MAKE_RECURSIVE_VARIANT_IMPL_START(_fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t);
   FX_COPY_FP(arg0, &v->u.Some);
   return 0;
}

FX_EXTERN_C void _fx_M10C_gen_codeFM4SomeNt6option1R9Ast__id_t1R9Ast__id_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_Nt6option1R9Ast__id_t* fx_result)
{
   fx_result->tag = 2;
   fx_result->u.Some = *arg0;
}

FX_EXTERN_C void _fx_M10C_gen_codeFM4SomeNt6option1i1i(int_ arg0, struct _fx_Nt6option1i* fx_result)
{
   fx_result->tag = 2;
   fx_result->u.Some = arg0;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6isnoneB1Nt6option1N14C_form__cexp_t(
   struct _fx_Nt6option1N14C_form__cexp_t* x_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (x_0->tag == 2) {
      *fx_result = false;
   }
   else {
      *fx_result = true;
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6issomeB1Nt6option1N14C_form__cexp_t(
   struct _fx_Nt6option1N14C_form__cexp_t* x_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (x_0->tag == 2) {
      *fx_result = true;
   }
   else {
      *fx_result = false;
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(
   struct _fx_R9Ast__id_t* a_0,
   struct _fx_R9Ast__id_t* b_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   bool res_0;
   FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(a_0, b_0, &res_0, 0), _fx_cleanup);
   *fx_result = !res_0;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int_
   _fx_M10C_gen_codeFM6lengthi1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* l,
   void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* l,
   void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LT2BN14K_form__atom_t(struct _fx_LT2BN14K_form__atom_t_data_t* l, void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LN14C_form__cexp_t(struct _fx_LN14C_form__cexp_t_data_t* l, void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* l,
   void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* l,
   void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LN13K_form__dom_t(struct _fx_LN13K_form__dom_t_data_t* l, void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LN14K_form__atom_t(struct _fx_LN14K_form__atom_t_data_t* l, void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LLT2BN14K_form__atom_t(struct _fx_LLT2BN14K_form__atom_t_data_t* l, void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LT2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* l,
   void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C int_ _fx_M10C_gen_codeFM6lengthi1LR9Ast__id_t(struct _fx_LR9Ast__id_t_data_t* l, void* fx_fv)
{
   
return fx_list_length(l);

}

FX_EXTERN_C void
   _fx_M10C_gen_codeFM5link2LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t2LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* l1,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* l2,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t** fx_result,
   void* fx_fv)
{
   
fx_link_lists(l1, l2, fx_result);

}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7__add__LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t2LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* l1_0,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* l2_0,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (l1_0 == 0) {
      FX_COPY_PTR(l2_0, fx_result);
   }
   else if (l2_0 == 0) {
      FX_COPY_PTR(l1_0, fx_result);
   }
   else {
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_0 = 0;
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t lstend_0 = 0;
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t lst_0 = l1_0;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* x_0 = &lst_0->hd;
         _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t node_0 = 0;
         FX_CALL(_fx_cons_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(x_0, 0, false, &node_0), _fx_catch_0);
         FX_LIST_APPEND(v_0, lstend_0, node_0);

      _fx_catch_0: ;
         FX_CHECK_EXN(_fx_catch_1);
      }
      _fx_M10C_gen_codeFM5link2LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t2LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
         v_0, l2_0, fx_result, 0);

   _fx_catch_1: ;
      if (v_0) {
         _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_0);
      }
   }
   return fx_status;
}

FX_EXTERN_C void _fx_M10C_gen_codeFM5link2LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* l1,
   struct _fx_LN14C_form__cexp_t_data_t* l2,
   struct _fx_LN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   
fx_link_lists(l1, l2, fx_result);

}

FX_EXTERN_C int _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* l1_0,
   struct _fx_LN14C_form__cexp_t_data_t* l2_0,
   struct _fx_LN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (l1_0 == 0) {
      FX_COPY_PTR(l2_0, fx_result);
   }
   else if (l2_0 == 0) {
      FX_COPY_PTR(l1_0, fx_result);
   }
   else {
      _fx_LN14C_form__cexp_t v_0 = 0;
      _fx_LN14C_form__cexp_t lstend_0 = 0;
      _fx_LN14C_form__cexp_t lst_0 = l1_0;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_N14C_form__cexp_t x_0 = lst_0->hd;
         _fx_LN14C_form__cexp_t node_0 = 0;
         FX_CALL(_fx_cons_LN14C_form__cexp_t(x_0, 0, false, &node_0), _fx_catch_0);
         FX_LIST_APPEND(v_0, lstend_0, node_0);

      _fx_catch_0: ;
         FX_CHECK_EXN(_fx_catch_1);
      }
      _fx_M10C_gen_codeFM5link2LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(v_0, l2_0, fx_result, 0);

   _fx_catch_1: ;
      if (v_0) {
         _fx_free_LN14C_form__cexp_t(&v_0);
      }
   }
   return fx_status;
}

FX_EXTERN_C void _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* l1,
   struct _fx_LN15C_form__cstmt_t_data_t* l2,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   
fx_link_lists(l1, l2, fx_result);

}

FX_EXTERN_C int _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* l1_0,
   struct _fx_LN15C_form__cstmt_t_data_t* l2_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (l1_0 == 0) {
      FX_COPY_PTR(l2_0, fx_result);
   }
   else if (l2_0 == 0) {
      FX_COPY_PTR(l1_0, fx_result);
   }
   else {
      _fx_LN15C_form__cstmt_t v_0 = 0;
      _fx_LN15C_form__cstmt_t lstend_0 = 0;
      _fx_LN15C_form__cstmt_t lst_0 = l1_0;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_N15C_form__cstmt_t x_0 = lst_0->hd;
         _fx_LN15C_form__cstmt_t node_0 = 0;
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_0, 0, false, &node_0), _fx_catch_0);
         FX_LIST_APPEND(v_0, lstend_0, node_0);

      _fx_catch_0: ;
         FX_CHECK_EXN(_fx_catch_1);
      }
      _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_0, l2_0, fx_result, 0);

   _fx_catch_1: ;
      if (v_0) {
         _fx_free_LN15C_form__cstmt_t(&v_0);
      }
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6stringS1S(fx_str_t* a_0, fx_str_t* fx_result, void* fx_fv)
{
   int fx_status = 0;
   fx_copy_str(a_0, fx_result);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6stringS1T2SR9Ast__id_t(struct _fx_T2SR9Ast__id_t* t_0, fx_str_t* fx_result, void* fx_fv)
{
   fx_str_t x_0 = {0};
   fx_str_t v_0 = {0};
   fx_str_t v_1 = {0};
   fx_arr_t v_2 = {0};
   int fx_status = 0;
   fx_copy_str(&t_0->t0, &x_0);
   FX_CALL(_fx_F4reprS1S(&x_0, &v_0, 0), _fx_cleanup);
   _fx_R9Ast__id_t x_1 = t_0->t1;
   FX_CALL(_fx_M3AstFM6stringS1RM4id_t(&x_1, &v_1, 0), _fx_cleanup);
   {
      const int_ shape_0[] = { 2 };
      const fx_str_t data_0[] = { v_0, v_1 };
      FX_CALL(fx_make_arr(1, shape_0, sizeof(fx_str_t), (fx_free_t)fx_free_str, (fx_copy_t)fx_copy_str, data_0, &v_2),
         _fx_cleanup);
   }
   fx_str_t slit_0 = FX_MAKE_STR("(");
   fx_str_t slit_1 = FX_MAKE_STR(")");
   fx_str_t slit_2 = FX_MAKE_STR(", ");
   FX_CALL(_fx_F12join_embraceS4SSSA1S(&slit_0, &slit_1, &slit_2, &v_2, fx_result, 0), _fx_cleanup);

_fx_cleanup: ;
   FX_FREE_STR(&x_0);
   FX_FREE_STR(&v_0);
   FX_FREE_STR(&v_1);
   FX_FREE_ARR(&v_2);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6__eq__B2LN14C_form__ctyp_tLN14C_form__ctyp_t(
   struct _fx_LN14C_form__ctyp_t_data_t* a_0,
   struct _fx_LN14C_form__ctyp_t_data_t* b_0,
   bool* fx_result,
   void* fx_fv)
{
   _fx_LN14C_form__ctyp_t a_1 = 0;
   _fx_LN14C_form__ctyp_t b_1 = 0;
   int fx_status = 0;
   FX_CALL(fx_check_stack(), _fx_cleanup);
   bool result_0 = 0;
   FX_COPY_PTR(a_0, &a_1);
   FX_COPY_PTR(b_0, &b_1);
   for (;;) {
      _fx_LN14C_form__ctyp_t a_2 = 0;
      _fx_LN14C_form__ctyp_t b_2 = 0;
      FX_COPY_PTR(a_1, &a_2);
      FX_COPY_PTR(b_1, &b_2);
      if (_fx_M10C_gen_codeFM8__same__B2LN14C_form__ctyp_tLN14C_form__ctyp_t(a_2, b_2, 0)) {
         result_0 = true; FX_BREAK(_fx_catch_3);
      }
      else {
         if (b_2 != 0) {
            if (a_2 != 0) {
               bool res_0;
               FX_CALL(_fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(a_2->hd, b_2->hd, &res_0, 0),
                  _fx_catch_0);
               if (res_0) {
                  _fx_LN14C_form__ctyp_t* a_3 = &a_2->tl;
                  _fx_free_LN14C_form__ctyp_t(&a_1);
                  FX_COPY_PTR(*a_3, &a_1);
                  _fx_LN14C_form__ctyp_t* b_3 = &b_2->tl;
                  _fx_free_LN14C_form__ctyp_t(&b_1);
                  FX_COPY_PTR(*b_3, &b_1);
               }
               else {
                  result_0 = false; FX_BREAK(_fx_catch_0);
               }

            _fx_catch_0: ;
               goto _fx_endmatch_0;
            }
         }
         if (b_2 == 0) {
            if (a_2 == 0) {
               result_0 = true; FX_BREAK(_fx_catch_1);  _fx_catch_1: ; goto _fx_endmatch_0;
            }
         }
         result_0 = false;
         FX_BREAK(_fx_catch_2);

      _fx_catch_2: ;

      _fx_endmatch_0: ;
         FX_CHECK_EXN(_fx_catch_3);
      }

   _fx_catch_3: ;
      if (b_2) {
         _fx_free_LN14C_form__ctyp_t(&b_2);
      }
      if (a_2) {
         _fx_free_LN14C_form__ctyp_t(&a_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = result_0;

_fx_cleanup: ;
   if (a_1) {
      _fx_free_LN14C_form__ctyp_t(&a_1);
   }
   if (b_1) {
      _fx_free_LN14C_form__ctyp_t(&b_1);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6__eq__B2LT2R9Ast__id_tN14C_form__ctyp_tLT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* a_0,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* b_0,
   bool* fx_result,
   void* fx_fv)
{
   _fx_LT2R9Ast__id_tN14C_form__ctyp_t a_1 = 0;
   _fx_LT2R9Ast__id_tN14C_form__ctyp_t b_1 = 0;
   int fx_status = 0;
   FX_CALL(fx_check_stack(), _fx_cleanup);
   bool result_0 = 0;
   FX_COPY_PTR(a_0, &a_1);
   FX_COPY_PTR(b_0, &b_1);
   for (;;) {
      _fx_LT2R9Ast__id_tN14C_form__ctyp_t a_2 = 0;
      _fx_LT2R9Ast__id_tN14C_form__ctyp_t b_2 = 0;
      FX_COPY_PTR(a_1, &a_2);
      FX_COPY_PTR(b_1, &b_2);
      if (_fx_M10C_gen_codeFM8__same__B2LT2R9Ast__id_tN14C_form__ctyp_tLT2R9Ast__id_tN14C_form__ctyp_t(a_2, b_2, 0)) {
         result_0 = true; FX_BREAK(_fx_catch_3);
      }
      else {
         if (b_2 != 0) {
            if (a_2 != 0) {
               bool res_0;
               FX_CALL(
                  _fx_M10C_gen_codeFM6__eq__B2T2R9Ast__id_tN14C_form__ctyp_tT2R9Ast__id_tN14C_form__ctyp_t(&a_2->hd, &b_2->hd,
                     &res_0, 0), _fx_catch_0);
               if (res_0) {
                  _fx_LT2R9Ast__id_tN14C_form__ctyp_t* a_3 = &a_2->tl;
                  _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&a_1);
                  FX_COPY_PTR(*a_3, &a_1);
                  _fx_LT2R9Ast__id_tN14C_form__ctyp_t* b_3 = &b_2->tl;
                  _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&b_1);
                  FX_COPY_PTR(*b_3, &b_1);
               }
               else {
                  result_0 = false; FX_BREAK(_fx_catch_0);
               }

            _fx_catch_0: ;
               goto _fx_endmatch_0;
            }
         }
         if (b_2 == 0) {
            if (a_2 == 0) {
               result_0 = true; FX_BREAK(_fx_catch_1);  _fx_catch_1: ; goto _fx_endmatch_0;
            }
         }
         result_0 = false;
         FX_BREAK(_fx_catch_2);

      _fx_catch_2: ;

      _fx_endmatch_0: ;
         FX_CHECK_EXN(_fx_catch_3);
      }

   _fx_catch_3: ;
      if (b_2) {
         _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&b_2);
      }
      if (a_2) {
         _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&a_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = result_0;

_fx_cleanup: ;
   if (a_1) {
      _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&a_1);
   }
   if (b_1) {
      _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&b_1);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6__eq__B2T2R9Ast__id_tN14C_form__ctyp_tT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* a_0,
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* b_0,
   bool* fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t aj_0 = 0;
   _fx_N14C_form__ctyp_t bj_0 = 0;
   int fx_status = 0;
   FX_CALL(fx_check_stack(), _fx_cleanup);
   bool __fold_result___0 = true;
   _fx_R9Ast__id_t aj_1 = a_0->t0;
   _fx_R9Ast__id_t bj_1 = b_0->t0;
   bool res_0;
   FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&aj_1, &bj_1, &res_0, 0), _fx_cleanup);
   bool t_0;
   if (res_0) {
      t_0 = __fold_result___0;
   }
   else {
      t_0 = false;
   }
   __fold_result___0 = t_0;
   FX_COPY_PTR(a_0->t1, &aj_0);
   FX_COPY_PTR(b_0->t1, &bj_0);
   bool v_0;
   FX_CALL(_fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(aj_0, bj_0, &v_0, 0), _fx_cleanup);
   bool t_1;
   if (v_0) {
      t_1 = __fold_result___0;
   }
   else {
      t_1 = false;
   }
   __fold_result___0 = t_1;
   *fx_result = __fold_result___0;

_fx_cleanup: ;
   if (aj_0) {
      _fx_free_N14C_form__ctyp_t(&aj_0);
   }
   if (bj_0) {
      _fx_free_N14C_form__ctyp_t(&bj_0);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6__eq__B2R10Ast__loc_tR10Ast__loc_t(
   struct _fx_R10Ast__loc_t* a_0,
   struct _fx_R10Ast__loc_t* b_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   bool __fold_result___0 = true;
   bool t_0;
   if (a_0->m_idx == b_0->m_idx) {
      t_0 = __fold_result___0;
   }
   else {
      t_0 = false;
   }
   __fold_result___0 = t_0;
   bool t_1;
   if (a_0->line0 == b_0->line0) {
      t_1 = __fold_result___0;
   }
   else {
      t_1 = false;
   }
   __fold_result___0 = t_1;
   bool t_2;
   if (a_0->col0 == b_0->col0) {
      t_2 = __fold_result___0;
   }
   else {
      t_2 = false;
   }
   __fold_result___0 = t_2;
   bool t_3;
   if (a_0->line1 == b_0->line1) {
      t_3 = __fold_result___0;
   }
   else {
      t_3 = false;
   }
   __fold_result___0 = t_3;
   bool t_4;
   if (a_0->col1 == b_0->col1) {
      t_4 = __fold_result___0;
   }
   else {
      t_4 = false;
   }
   __fold_result___0 = t_4;
   *fx_result = __fold_result___0;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(
   struct _fx_N14C_form__ctyp_t_data_t* a_0,
   struct _fx_N14C_form__ctyp_t_data_t* b_0,
   bool* fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t a_1 = 0;
   _fx_N14C_form__ctyp_t b_1 = 0;
   int fx_status = 0;
   FX_CALL(fx_check_stack(), _fx_cleanup);
   bool result_0 = 0;
   FX_COPY_PTR(a_0, &a_1);
   FX_COPY_PTR(b_0, &b_1);
   for (;;) {
      _fx_N14C_form__ctyp_t a_2 = 0;
      _fx_N14C_form__ctyp_t b_2 = 0;
      FX_COPY_PTR(a_1, &a_2);
      FX_COPY_PTR(b_1, &b_2);
      if (FX_REC_VARIANT_TAG(b_2) == 4) {
         if (FX_REC_VARIANT_TAG(a_2) == 4) {
            result_0 = a_2->u.CTypSInt == b_2->u.CTypSInt; FX_BREAK(_fx_catch_0);  _fx_catch_0: ; goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 5) {
         if (FX_REC_VARIANT_TAG(a_2) == 5) {
            result_0 = a_2->u.CTypUInt == b_2->u.CTypUInt; FX_BREAK(_fx_catch_1);  _fx_catch_1: ; goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 7) {
         if (FX_REC_VARIANT_TAG(a_2) == 7) {
            result_0 = a_2->u.CTypFloat == b_2->u.CTypFloat; FX_BREAK(_fx_catch_2);  _fx_catch_2: ; goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 14) {
         _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* vcase_0 = &b_2->u.CTypStruct;
         if (FX_REC_VARIANT_TAG(a_2) == 14) {
            _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* vcase_1 = &a_2->u.CTypStruct;
            _fx_Nt6option1R9Ast__id_t* a0_0 = &vcase_1->t0;
            _fx_Nt6option1R9Ast__id_t* b0_0 = &vcase_0->t0;
            bool res_0;
            if (b0_0->tag == 2) {
               if (a0_0->tag == 2) {
                  FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&a0_0->u.Some, &b0_0->u.Some, &res_0, 0), _fx_catch_3);

               _fx_catch_3: ;
                  goto _fx_endmatch_0;
               }
            }
            if (a0_0->tag == 1) {
               if (b0_0->tag == 1) {
                  res_0 = true; goto _fx_endmatch_0;
               }
            }
            res_0 = false;

         _fx_endmatch_0: ;
            FX_CHECK_EXN(_fx_catch_4);
            bool v_0;
            FX_CALL(
               _fx_M10C_gen_codeFM6__eq__B2LT2R9Ast__id_tN14C_form__ctyp_tLT2R9Ast__id_tN14C_form__ctyp_t(vcase_1->t1,
                  vcase_0->t1, &v_0, 0), _fx_catch_4);
            result_0 = (bool)(res_0 & v_0);
            FX_BREAK(_fx_catch_4);

         _fx_catch_4: ;
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 15) {
         _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* vcase_2 = &b_2->u.CTypUnion;
         if (FX_REC_VARIANT_TAG(a_2) == 15) {
            _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* vcase_3 = &a_2->u.CTypUnion;
            _fx_Nt6option1R9Ast__id_t* a0_1 = &vcase_3->t0;
            _fx_Nt6option1R9Ast__id_t* b0_1 = &vcase_2->t0;
            bool res_1;
            if (b0_1->tag == 2) {
               if (a0_1->tag == 2) {
                  FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&a0_1->u.Some, &b0_1->u.Some, &res_1, 0), _fx_catch_5);

               _fx_catch_5: ;
                  goto _fx_endmatch_1;
               }
            }
            if (a0_1->tag == 1) {
               if (b0_1->tag == 1) {
                  res_1 = true; goto _fx_endmatch_1;
               }
            }
            res_1 = false;

         _fx_endmatch_1: ;
            FX_CHECK_EXN(_fx_catch_6);
            bool v_1;
            FX_CALL(
               _fx_M10C_gen_codeFM6__eq__B2LT2R9Ast__id_tN14C_form__ctyp_tLT2R9Ast__id_tN14C_form__ctyp_t(vcase_3->t1,
                  vcase_2->t1, &v_1, 0), _fx_catch_6);
            result_0 = (bool)(res_1 & v_1);
            FX_BREAK(_fx_catch_6);

         _fx_catch_6: ;
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 16) {
         _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t* vcase_4 = &b_2->u.CTypFunRawPtr;
         if (FX_REC_VARIANT_TAG(a_2) == 16) {
            _fx_T2LN14C_form__ctyp_tN14C_form__ctyp_t* vcase_5 = &a_2->u.CTypFunRawPtr;
            bool v_2;
            FX_CALL(_fx_M10C_gen_codeFM6__eq__B2LN14C_form__ctyp_tLN14C_form__ctyp_t(vcase_5->t0, vcase_4->t0, &v_2, 0),
               _fx_catch_7);
            bool v_3;
            FX_CALL(_fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(vcase_5->t1, vcase_4->t1, &v_3, 0),
               _fx_catch_7);
            result_0 = (bool)(v_2 & v_3);
            FX_BREAK(_fx_catch_7);

         _fx_catch_7: ;
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 17) {
         _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* vcase_6 = &b_2->u.CTypRawPtr;
         if (FX_REC_VARIANT_TAG(a_2) == 17) {
            _fx_LN19C_form__ctyp_attr_t a_3 = 0;
            _fx_LN19C_form__ctyp_attr_t b_3 = 0;
            _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* vcase_7 = &a_2->u.CTypRawPtr;
            bool result_1 = 0;
            FX_COPY_PTR(vcase_7->t0, &a_3);
            FX_COPY_PTR(vcase_6->t0, &b_3);
            for (;;) {
               _fx_LN19C_form__ctyp_attr_t a_4 = 0;
               _fx_LN19C_form__ctyp_attr_t b_4 = 0;
               FX_COPY_PTR(a_3, &a_4);
               FX_COPY_PTR(b_3, &b_4);
               if (_fx_M10C_gen_codeFM8__same__B2LN19C_form__ctyp_attr_tLN19C_form__ctyp_attr_t(a_4, b_4, 0)) {
                  result_1 = true; FX_BREAK(_fx_catch_11);
               }
               else {
                  if (b_4 != 0) {
                     if (a_4 != 0) {
                        if (a_4->hd.tag == b_4->hd.tag) {
                           _fx_LN19C_form__ctyp_attr_t* a_5 = &a_4->tl;
                           FX_FREE_LIST_SIMPLE(&a_3);
                           FX_COPY_PTR(*a_5, &a_3);
                           _fx_LN19C_form__ctyp_attr_t* b_5 = &b_4->tl;
                           FX_FREE_LIST_SIMPLE(&b_3);
                           FX_COPY_PTR(*b_5, &b_3);
                        }
                        else {
                           result_1 = false; FX_BREAK(_fx_catch_8);
                        }

                     _fx_catch_8: ;
                        goto _fx_endmatch_2;
                     }
                  }
                  if (b_4 == 0) {
                     if (a_4 == 0) {
                        result_1 = true; FX_BREAK(_fx_catch_9);  _fx_catch_9: ; goto _fx_endmatch_2;
                     }
                  }
                  result_1 = false;
                  FX_BREAK(_fx_catch_10);

               _fx_catch_10: ;

               _fx_endmatch_2: ;
                  FX_CHECK_EXN(_fx_catch_11);
               }

            _fx_catch_11: ;
               FX_FREE_LIST_SIMPLE(&b_4);
               FX_FREE_LIST_SIMPLE(&a_4);
               FX_CHECK_BREAK();
               FX_CHECK_EXN(_fx_catch_12);
            }
            bool v_4;
            FX_CALL(_fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(vcase_7->t1, vcase_6->t1, &v_4, 0),
               _fx_catch_12);
            result_0 = (bool)(result_1 & v_4);
            FX_BREAK(_fx_catch_12);

         _fx_catch_12: ;
            FX_FREE_LIST_SIMPLE(&b_3);
            FX_FREE_LIST_SIMPLE(&a_3);
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 18) {
         _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* vcase_8 = &b_2->u.CTypRawArray;
         if (FX_REC_VARIANT_TAG(a_2) == 18) {
            _fx_LN19C_form__ctyp_attr_t a_6 = 0;
            _fx_LN19C_form__ctyp_attr_t b_6 = 0;
            _fx_T2LN19C_form__ctyp_attr_tN14C_form__ctyp_t* vcase_9 = &a_2->u.CTypRawArray;
            bool result_2 = 0;
            FX_COPY_PTR(vcase_9->t0, &a_6);
            FX_COPY_PTR(vcase_8->t0, &b_6);
            for (;;) {
               _fx_LN19C_form__ctyp_attr_t a_7 = 0;
               _fx_LN19C_form__ctyp_attr_t b_7 = 0;
               FX_COPY_PTR(a_6, &a_7);
               FX_COPY_PTR(b_6, &b_7);
               if (_fx_M10C_gen_codeFM8__same__B2LN19C_form__ctyp_attr_tLN19C_form__ctyp_attr_t(a_7, b_7, 0)) {
                  result_2 = true; FX_BREAK(_fx_catch_16);
               }
               else {
                  if (b_7 != 0) {
                     if (a_7 != 0) {
                        if (a_7->hd.tag == b_7->hd.tag) {
                           _fx_LN19C_form__ctyp_attr_t* a_8 = &a_7->tl;
                           FX_FREE_LIST_SIMPLE(&a_6);
                           FX_COPY_PTR(*a_8, &a_6);
                           _fx_LN19C_form__ctyp_attr_t* b_8 = &b_7->tl;
                           FX_FREE_LIST_SIMPLE(&b_6);
                           FX_COPY_PTR(*b_8, &b_6);
                        }
                        else {
                           result_2 = false; FX_BREAK(_fx_catch_13);
                        }

                     _fx_catch_13: ;
                        goto _fx_endmatch_3;
                     }
                  }
                  if (b_7 == 0) {
                     if (a_7 == 0) {
                        result_2 = true; FX_BREAK(_fx_catch_14);  _fx_catch_14: ; goto _fx_endmatch_3;
                     }
                  }
                  result_2 = false;
                  FX_BREAK(_fx_catch_15);

               _fx_catch_15: ;

               _fx_endmatch_3: ;
                  FX_CHECK_EXN(_fx_catch_16);
               }

            _fx_catch_16: ;
               FX_FREE_LIST_SIMPLE(&b_7);
               FX_FREE_LIST_SIMPLE(&a_7);
               FX_CHECK_BREAK();
               FX_CHECK_EXN(_fx_catch_17);
            }
            bool v_5;
            FX_CALL(_fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(vcase_9->t1, vcase_8->t1, &v_5, 0),
               _fx_catch_17);
            result_0 = (bool)(result_2 & v_5);
            FX_BREAK(_fx_catch_17);

         _fx_catch_17: ;
            FX_FREE_LIST_SIMPLE(&b_6);
            FX_FREE_LIST_SIMPLE(&a_6);
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 19) {
         _fx_T2iN14C_form__ctyp_t* vcase_10 = &b_2->u.CTypArray;
         if (FX_REC_VARIANT_TAG(a_2) == 19) {
            _fx_T2iN14C_form__ctyp_t* vcase_11 = &a_2->u.CTypArray;
            bool v_6;
            FX_CALL(
               _fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(vcase_11->t1, vcase_10->t1, &v_6, 0),
               _fx_catch_18);
            result_0 = (bool)((vcase_11->t0 == vcase_10->t0) & v_6);
            FX_BREAK(_fx_catch_18);

         _fx_catch_18: ;
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 20) {
         if (FX_REC_VARIANT_TAG(a_2) == 20) {
            _fx_N14C_form__ctyp_t* a0_2 = &a_2->u.CTypVector;
            _fx_free_N14C_form__ctyp_t(&a_1);
            FX_COPY_PTR(*a0_2, &a_1);
            _fx_N14C_form__ctyp_t* b0_2 = &b_2->u.CTypVector;
            _fx_free_N14C_form__ctyp_t(&b_1);
            FX_COPY_PTR(*b0_2, &b_1);
            goto _fx_endmatch_4;
         }
      }
      if (FX_REC_VARIANT_TAG(b_2) == 21) {
         if (FX_REC_VARIANT_TAG(a_2) == 21) {
            bool res_2;
            FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&a_2->u.CTypName, &b_2->u.CTypName, &res_2, 0), _fx_catch_19);
            result_0 = res_2;
            FX_BREAK(_fx_catch_19);

         _fx_catch_19: ;
            goto _fx_endmatch_4;
         }
      }
      result_0 = FX_REC_VARIANT_TAG(a_2) == FX_REC_VARIANT_TAG(b_2);
      FX_BREAK(_fx_catch_20);

   _fx_catch_20: ;

   _fx_endmatch_4: ;
      FX_CHECK_EXN(_fx_catch_21);

   _fx_catch_21: ;
      if (b_2) {
         _fx_free_N14C_form__ctyp_t(&b_2);
      }
      if (a_2) {
         _fx_free_N14C_form__ctyp_t(&a_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = result_0;

_fx_cleanup: ;
   if (a_1) {
      _fx_free_N14C_form__ctyp_t(&a_1);
   }
   if (b_1) {
      _fx_free_N14C_form__ctyp_t(&b_1);
   }
   return fx_status;
}

FX_EXTERN_C bool _fx_M10C_gen_codeFM8__same__B2LN19C_form__ctyp_attr_tLN19C_form__ctyp_attr_t(
   struct _fx_LN19C_form__ctyp_attr_t_data_t* a,
   struct _fx_LN19C_form__ctyp_attr_t_data_t* b,
   void* fx_fv)
{
   
return a == b;

}

FX_EXTERN_C bool _fx_M10C_gen_codeFM8__same__B2LN14C_form__ctyp_tLN14C_form__ctyp_t(
   struct _fx_LN14C_form__ctyp_t_data_t* a,
   struct _fx_LN14C_form__ctyp_t_data_t* b,
   void* fx_fv)
{
   
return a == b;

}

FX_EXTERN_C bool _fx_M10C_gen_codeFM8__same__B2LT2R9Ast__id_tN14C_form__ctyp_tLT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* a,
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* b,
   void* fx_fv)
{
   
return a == b;

}

FX_EXTERN_C int _fx_M10C_gen_codeFM3inti1l(int64_t x_0, int_* fx_result, void* fx_fv)
{
   int fx_status = 0;
   *fx_result = (int_)x_0;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM5int64l1i(int_ x_0, int64_t* fx_result, void* fx_fv)
{
   int fx_status = 0;
   *fx_result = (int64_t)x_0;
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM8length1_i1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result =
      _fx_M10C_gen_codeFM6lengthi1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LT2R9Ast__id_tN14C_form__ctyp_t(
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LT2R9Ast__id_tN14C_form__ctyp_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LT2BN14K_form__atom_t(
   struct _fx_LT2BN14K_form__atom_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LT2BN14K_form__atom_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LN14C_form__cexp_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LN13K_form__dom_t(
   struct _fx_LN13K_form__dom_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LN13K_form__dom_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LN14K_form__atom_t(
   struct _fx_LN14K_form__atom_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LN14K_form__atom_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LLT2BN14K_form__atom_t(
   struct _fx_LLT2BN14K_form__atom_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LLT2BN14K_form__atom_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8length1_i1LT2R9Ast__id_tN14K_form__ktyp_t(
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* l_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   *fx_result = _fx_M10C_gen_codeFM6lengthi1LT2R9Ast__id_tN14K_form__ktyp_t(l_0, 0);
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM2hdT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t1LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* __pat___0,
   struct _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (__pat___0 != 0) {
      _fx_copy_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&__pat___0->hd,
         fx_result);
   }
   else {
      FX_FAST_THROW(FX_EXN_NullListError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM2hdLT2BN14K_form__atom_t1LLT2BN14K_form__atom_t(
   struct _fx_LLT2BN14K_form__atom_t_data_t* __pat___0,
   struct _fx_LT2BN14K_form__atom_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (__pat___0 != 0) {
      FX_COPY_PTR(__pat___0->hd, fx_result);
   }
   else {
      FX_FAST_THROW(FX_EXN_NullListError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM2hdN14C_form__cexp_t1LN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* __pat___0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (__pat___0 != 0) {
      FX_COPY_PTR(__pat___0->hd, fx_result);
   }
   else {
      FX_FAST_THROW(FX_EXN_NullListError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM2hdN14K_form__atom_t1LN14K_form__atom_t(
   struct _fx_LN14K_form__atom_t_data_t* __pat___0,
   struct _fx_N14K_form__atom_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (__pat___0 != 0) {
      _fx_copy_N14K_form__atom_t(&__pat___0->hd, fx_result);
   }
   else {
      FX_FAST_THROW(FX_EXN_NullListError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM2hdN14K_form__kexp_t1LN14K_form__kexp_t(
   struct _fx_LN14K_form__kexp_t_data_t* __pat___0,
   struct _fx_N14K_form__kexp_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (__pat___0 != 0) {
      FX_COPY_PTR(__pat___0->hd, fx_result);
   }
   else {
      FX_FAST_THROW(FX_EXN_NullListError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM2tlLN14C_form__cexp_t1LN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* __pat___0,
   struct _fx_LN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (__pat___0 != 0) {
      FX_COPY_PTR(__pat___0->tl, fx_result);
   }
   else {
      FX_FAST_THROW(FX_EXN_NullListError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3nthT2R9Ast__id_tN14C_form__ctyp_t2LT2R9Ast__id_tN14C_form__ctyp_ti(
   struct _fx_LT2R9Ast__id_tN14C_form__ctyp_t_data_t* l_0,
   int_ n_0,
   struct _fx_T2R9Ast__id_tN14C_form__ctyp_t* fx_result,
   void* fx_fv)
{
   _fx_T2R9Ast__id_tN14C_form__ctyp_t result_0 = {0};
   _fx_LT2R9Ast__id_tN14C_form__ctyp_t l_1 = 0;
   int fx_status = 0;
   FX_COPY_PTR(l_0, &l_1);
   int_ n_1 = n_0;
   for (;;) {
      _fx_LT2R9Ast__id_tN14C_form__ctyp_t l_2 = 0;
      FX_COPY_PTR(l_1, &l_2);
      int_ n_2 = n_1;
      if (l_2 != 0) {
         if (n_2 == 0) {
            _fx_T2R9Ast__id_tN14C_form__ctyp_t* a_0 = &l_2->hd;
            _fx_free_T2R9Ast__id_tN14C_form__ctyp_t(&result_0);
            _fx_copy_T2R9Ast__id_tN14C_form__ctyp_t(a_0, &result_0);
            FX_BREAK(_fx_catch_0);
         }
         else {
            _fx_LT2R9Ast__id_tN14C_form__ctyp_t* rest_0 = &l_2->tl;
            _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&l_1);
            FX_COPY_PTR(*rest_0, &l_1);
            n_1 = n_2 - 1;
         }

      _fx_catch_0: ;
      }
      else {
         FX_FAST_THROW(FX_EXN_OutOfRangeError, _fx_catch_1);
      }
      FX_CHECK_EXN(_fx_catch_1);

   _fx_catch_1: ;
      if (l_2) {
         _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&l_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T2R9Ast__id_tN14C_form__ctyp_t(&result_0, fx_result);

_fx_cleanup: ;
   _fx_free_T2R9Ast__id_tN14C_form__ctyp_t(&result_0);
   if (l_1) {
      _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&l_1);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3nthS2LSi(struct _fx_LS_data_t* l_0, int_ n_0, fx_str_t* fx_result, void* fx_fv)
{
   fx_str_t result_0 = {0};
   _fx_LS l_1 = 0;
   int fx_status = 0;
   FX_COPY_PTR(l_0, &l_1);
   int_ n_1 = n_0;
   for (;;) {
      _fx_LS l_2 = 0;
      FX_COPY_PTR(l_1, &l_2);
      int_ n_2 = n_1;
      if (l_2 != 0) {
         if (n_2 == 0) {
            fx_str_t* a_0 = &l_2->hd; FX_FREE_STR(&result_0); fx_copy_str(a_0, &result_0); FX_BREAK(_fx_catch_0);
         }
         else {
            _fx_LS* rest_0 = &l_2->tl; _fx_free_LS(&l_1); FX_COPY_PTR(*rest_0, &l_1); n_1 = n_2 - 1;
         }

      _fx_catch_0: ;
      }
      else {
         FX_FAST_THROW(FX_EXN_OutOfRangeError, _fx_catch_1);
      }
      FX_CHECK_EXN(_fx_catch_1);

   _fx_catch_1: ;
      if (l_2) {
         _fx_free_LS(&l_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   fx_copy_str(&result_0, fx_result);

_fx_cleanup: ;
   FX_FREE_STR(&result_0);
   if (l_1) {
      _fx_free_LS(&l_1);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3nthR9Ast__id_t2LR9Ast__id_ti(
   struct _fx_LR9Ast__id_t_data_t* l_0,
   int_ n_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv)
{
   _fx_LR9Ast__id_t l_1 = 0;
   int fx_status = 0;
   _fx_R9Ast__id_t result_0 = {0};
   FX_COPY_PTR(l_0, &l_1);
   int_ n_1 = n_0;
   for (;;) {
      _fx_LR9Ast__id_t l_2 = 0;
      FX_COPY_PTR(l_1, &l_2);
      int_ n_2 = n_1;
      if (l_2 != 0) {
         if (n_2 == 0) {
            result_0 = l_2->hd; FX_BREAK(_fx_catch_0);
         }
         else {
            _fx_LR9Ast__id_t* rest_0 = &l_2->tl; FX_FREE_LIST_SIMPLE(&l_1); FX_COPY_PTR(*rest_0, &l_1); n_1 = n_2 - 1;
         }

      _fx_catch_0: ;
      }
      else {
         FX_FAST_THROW(FX_EXN_OutOfRangeError, _fx_catch_1);
      }
      FX_CHECK_EXN(_fx_catch_1);

   _fx_catch_1: ;
      FX_FREE_LIST_SIMPLE(&l_2);
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = result_0;

_fx_cleanup: ;
   FX_FREE_LIST_SIMPLE(&l_1);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3nthT2R9Ast__id_tN14K_form__ktyp_t2LT2R9Ast__id_tN14K_form__ktyp_ti(
   struct _fx_LT2R9Ast__id_tN14K_form__ktyp_t_data_t* l_0,
   int_ n_0,
   struct _fx_T2R9Ast__id_tN14K_form__ktyp_t* fx_result,
   void* fx_fv)
{
   _fx_T2R9Ast__id_tN14K_form__ktyp_t result_0 = {0};
   _fx_LT2R9Ast__id_tN14K_form__ktyp_t l_1 = 0;
   int fx_status = 0;
   FX_COPY_PTR(l_0, &l_1);
   int_ n_1 = n_0;
   for (;;) {
      _fx_LT2R9Ast__id_tN14K_form__ktyp_t l_2 = 0;
      FX_COPY_PTR(l_1, &l_2);
      int_ n_2 = n_1;
      if (l_2 != 0) {
         if (n_2 == 0) {
            _fx_T2R9Ast__id_tN14K_form__ktyp_t* a_0 = &l_2->hd;
            _fx_free_T2R9Ast__id_tN14K_form__ktyp_t(&result_0);
            _fx_copy_T2R9Ast__id_tN14K_form__ktyp_t(a_0, &result_0);
            FX_BREAK(_fx_catch_0);
         }
         else {
            _fx_LT2R9Ast__id_tN14K_form__ktyp_t* rest_0 = &l_2->tl;
            _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&l_1);
            FX_COPY_PTR(*rest_0, &l_1);
            n_1 = n_2 - 1;
         }

      _fx_catch_0: ;
      }
      else {
         FX_FAST_THROW(FX_EXN_OutOfRangeError, _fx_catch_1);
      }
      FX_CHECK_EXN(_fx_catch_1);

   _fx_catch_1: ;
      if (l_2) {
         _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&l_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T2R9Ast__id_tN14K_form__ktyp_t(&result_0, fx_result);

_fx_cleanup: ;
   _fx_free_T2R9Ast__id_tN14K_form__ktyp_t(&result_0);
   if (l_1) {
      _fx_free_LT2R9Ast__id_tN14K_form__ktyp_t(&l_1);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM3revLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t1LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* l_0,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t __fold_result___0 = 0;
   int fx_status = 0;
   _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t lst_0 = l_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t r_0 = 0;
      _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* a_0 = &lst_0->hd;
      FX_COPY_PTR(__fold_result___0, &r_0);
      FX_CALL(
         _fx_cons_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(a_0, r_0, false,
            &r_0), _fx_catch_0);
      _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&__fold_result___0);
      FX_COPY_PTR(r_0, &__fold_result___0);

   _fx_catch_0: ;
      if (r_0) {
         _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&__fold_result___0);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM3revLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t* l_0,
   struct _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t __fold_result___0 = 0;
   int fx_status = 0;
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t lst_0 = l_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t r_0 = 0;
      _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* a_0 = &lst_0->hd;
      FX_COPY_PTR(__fold_result___0, &r_0);
      FX_CALL(
         _fx_cons_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(a_0, r_0, false,
            &r_0), _fx_catch_0);
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         &__fold_result___0);
      FX_COPY_PTR(r_0, &__fold_result___0);

   _fx_catch_0: ;
      if (r_0) {
         _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         &__fold_result___0);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(
   struct _fx_LN14C_form__cexp_t_data_t* l_0,
   struct _fx_LN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LN14C_form__cexp_t __fold_result___0 = 0;
   int fx_status = 0;
   _fx_LN14C_form__cexp_t lst_0 = l_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LN14C_form__cexp_t r_0 = 0;
      _fx_N14C_form__cexp_t a_0 = lst_0->hd;
      FX_COPY_PTR(__fold_result___0, &r_0);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(a_0, r_0, false, &r_0), _fx_catch_0);
      _fx_free_LN14C_form__cexp_t(&__fold_result___0);
      FX_COPY_PTR(r_0, &__fold_result___0);

   _fx_catch_0: ;
      if (r_0) {
         _fx_free_LN14C_form__cexp_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LN14C_form__cexp_t(&__fold_result___0);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(
   struct _fx_LN15C_form__cstmt_t_data_t* l_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LN15C_form__cstmt_t __fold_result___0 = 0;
   int fx_status = 0;
   _fx_LN15C_form__cstmt_t lst_0 = l_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LN15C_form__cstmt_t r_0 = 0;
      _fx_N15C_form__cstmt_t a_0 = lst_0->hd;
      FX_COPY_PTR(__fold_result___0, &r_0);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(a_0, r_0, false, &r_0), _fx_catch_0);
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
      FX_COPY_PTR(r_0, &__fold_result___0);

   _fx_catch_0: ;
      if (r_0) {
         _fx_free_LN15C_form__cstmt_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3memB2LN19C_form__carg_attr_tN19C_form__carg_attr_t(
   struct _fx_LN19C_form__carg_attr_t_data_t* l_0,
   struct _fx_N19C_form__carg_attr_t* a_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   bool __fold_result___0 = false;
   _fx_LN19C_form__carg_attr_t lst_0 = l_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_N19C_form__carg_attr_t* b_0 = &lst_0->hd;
      if (a_0->tag == b_0->tag) {
         __fold_result___0 = true; FX_BREAK(_fx_catch_0);
      }

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = __fold_result___0;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM6concatLN15C_form__cstmt_t1LLN15C_form__cstmt_t(
   struct _fx_LLN15C_form__cstmt_t_data_t* ll_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LN15C_form__cstmt_t __fold_result___0 = 0;
   _fx_LLN15C_form__cstmt_t __fold_result___1 = 0;
   _fx_LLN15C_form__cstmt_t v_0 = 0;
   int fx_status = 0;
   _fx_LLN15C_form__cstmt_t lst_0 = ll_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LLN15C_form__cstmt_t r_0 = 0;
      _fx_LN15C_form__cstmt_t a_0 = lst_0->hd;
      FX_COPY_PTR(__fold_result___1, &r_0);
      FX_CALL(_fx_cons_LLN15C_form__cstmt_t(a_0, r_0, false, &r_0), _fx_catch_0);
      _fx_free_LLN15C_form__cstmt_t(&__fold_result___1);
      FX_COPY_PTR(r_0, &__fold_result___1);

   _fx_catch_0: ;
      if (r_0) {
         _fx_free_LLN15C_form__cstmt_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___1, &v_0);
   _fx_LLN15C_form__cstmt_t lst_1 = v_0;
   for (; lst_1; lst_1 = lst_1->tl) {
      _fx_LN15C_form__cstmt_t s_0 = 0;
      _fx_LN15C_form__cstmt_t v_1 = 0;
      _fx_LN15C_form__cstmt_t l_0 = lst_1->hd;
      FX_COPY_PTR(__fold_result___0, &s_0);
      if (l_0 == 0) {
         FX_COPY_PTR(s_0, &v_1);
      }
      else if (s_0 == 0) {
         FX_COPY_PTR(l_0, &v_1);
      }
      else {
         _fx_LN15C_form__cstmt_t v_2 = 0;
         _fx_LN15C_form__cstmt_t lstend_0 = 0;
         _fx_LN15C_form__cstmt_t lst_2 = l_0;
         for (; lst_2; lst_2 = lst_2->tl) {
            _fx_N15C_form__cstmt_t x_0 = lst_2->hd;
            _fx_LN15C_form__cstmt_t node_0 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_0, 0, false, &node_0), _fx_catch_1);
            FX_LIST_APPEND(v_2, lstend_0, node_0);

         _fx_catch_1: ;
            FX_CHECK_EXN(_fx_catch_2);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_2, s_0, &v_1, 0);

      _fx_catch_2: ;
         if (v_2) {
            _fx_free_LN15C_form__cstmt_t(&v_2);
         }
      }
      FX_CHECK_EXN(_fx_catch_3);
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
      FX_COPY_PTR(v_1, &__fold_result___0);

   _fx_catch_3: ;
      if (v_1) {
         _fx_free_LN15C_form__cstmt_t(&v_1);
      }
      if (s_0) {
         _fx_free_LN15C_form__cstmt_t(&s_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
   }
   if (__fold_result___1) {
      _fx_free_LLN15C_form__cstmt_t(&__fold_result___1);
   }
   if (v_0) {
      _fx_free_LLN15C_form__cstmt_t(&v_0);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM1tNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* arg0,
   int_ arg1,
   int_ arg2,
   int_ arg3,
   fx_arr_t* arg4,
   fx_arr_t* arg5,
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t** fx_result)
{
   FX_MAKE_RECURSIVE_VARIANT_IMPL_START(_fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t);
   _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(arg0, &v->u.t.t0);
   v->u.t.t1 = arg1;
   v->u.t.t2 = arg2;
   v->u.t.t3 = arg3;
   fx_copy_arr(arg4, &v->u.t.t4);
   fx_copy_arr(arg5, &v->u.t.t5);
   return 0;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM1tNt10Hashmap__t2R9Ast__id_ti6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti(
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti* arg0,
   int_ arg1,
   int_ arg2,
   int_ arg3,
   fx_arr_t* arg4,
   fx_arr_t* arg5,
   struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t** fx_result)
{
   FX_MAKE_RECURSIVE_VARIANT_IMPL_START(_fx_Nt10Hashmap__t2R9Ast__id_ti);
   v->u.t.t0 = *arg0;
   v->u.t.t1 = arg1;
   v->u.t.t2 = arg2;
   v->u.t.t3 = arg3;
   fx_copy_arr(arg4, &v->u.t.t4);
   fx_copy_arr(arg5, &v->u.t.t5);
   return 0;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM5emptyNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t3iR9Ast__id_tN14C_form__cexp_t(
   int_ size0_0,
   struct _fx_R9Ast__id_t* k0_0,
   struct _fx_N14C_form__cexp_t_data_t* d0_0,
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t entry0_0 = {0};
   fx_arr_t v_0 = {0};
   fx_arr_t v_1 = {0};
   int fx_status = 0;
   int_ size_0 = 8;
   while (size_0 < size0_0) {
      size_0 = size_0 * 2;
   }
   int_ idxsize_0 = size_0 * 2;
   _fx_make_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(0ULL, k0_0, d0_0, &entry0_0);
   FX_CALL(_fx_M7HashmapFM9makeindexA1i1i(idxsize_0, &v_0, 0), _fx_cleanup);
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* dstptr_0 = 0;
   int_ n_0 = size_0;
   {
      const int_ shape_0[] = { n_0 };
      FX_CALL(
         fx_make_arr(1, shape_0, sizeof(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t),
            (fx_free_t)_fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t,
            (fx_copy_t)_fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, 0, &v_1), _fx_cleanup);
   }
   dstptr_0 = (_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t*)v_1.data;
   for (int_ i_0 = 0; i_0 < n_0; i_0++, dstptr_0++) {
      _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&entry0_0, dstptr_0);
   }
   FX_CALL(
      _fx_M10C_gen_codeFM1tNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t6Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
         &entry0_0, 0, 0, 0, &v_0, &v_1, fx_result), _fx_cleanup);

_fx_cleanup: ;
   _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&entry0_0);
   FX_FREE_ARR(&v_0);
   FX_FREE_ARR(&v_1);
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM9add_fast_i4iA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tRt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
   int_ tabsz_0,
   fx_arr_t* ht_index_0,
   fx_arr_t* ht_table_0,
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* entry_0,
   int_* fx_result,
   void* fx_fv)
{
   fx_exn_t v_0 = {0};
   int fx_status = 0;
   int_ idxsz_0 = FX_ARR_SIZE(*ht_index_0, 0);
   uint64_t hv_0 = entry_0->hv;
   uint64_t perturb_0 = hv_0;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   bool found_free_slot_0 = false;
   int_ v_1 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_1; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(*ht_index_0, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, *ht_index_0, j_0);
      if (tidx_0 == 0) {
         FX_CHKIDX(FX_CHKIDX1(*ht_index_0, 0, j_0), _fx_catch_0);
         *FX_PTR_1D(int_, *ht_index_0, j_0) = tabsz_0 + 2;
         FX_CHKIDX(FX_CHKIDX1(*ht_table_0, 0, tabsz_0), _fx_catch_0);
         _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* v_2 =
            FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, *ht_table_0, tabsz_0);
         _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(v_2);
         _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(entry_0, v_2);
         found_free_slot_0 = true;
         FX_BREAK(_fx_catch_0);
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   if (!found_free_slot_0) {
      fx_str_t slit_0 = FX_MAKE_STR("cannot insert element (full Hashtable?!)");
      FX_CALL(_fx_F9make_FailE1S(&slit_0, &v_0), _fx_cleanup);
      FX_THROW(&v_0, true, _fx_cleanup);
   }
   *fx_result = tabsz_0 + 1;

_fx_cleanup: ;
   fx_free_exn(&v_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM9add_fast_i4iA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tiRt20Hashmap__hashentry_t2R9Ast__id_ti(
   int_ tabsz_0,
   fx_arr_t* ht_index_0,
   fx_arr_t* ht_table_0,
   struct _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti* entry_0,
   int_* fx_result,
   void* fx_fv)
{
   fx_exn_t v_0 = {0};
   int fx_status = 0;
   int_ idxsz_0 = FX_ARR_SIZE(*ht_index_0, 0);
   uint64_t hv_0 = entry_0->hv;
   uint64_t perturb_0 = hv_0;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   bool found_free_slot_0 = false;
   int_ v_1 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_1; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(*ht_index_0, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, *ht_index_0, j_0);
      if (tidx_0 == 0) {
         FX_CHKIDX(FX_CHKIDX1(*ht_index_0, 0, j_0), _fx_catch_0);
         *FX_PTR_1D(int_, *ht_index_0, j_0) = tabsz_0 + 2;
         FX_CHKIDX(FX_CHKIDX1(*ht_table_0, 0, tabsz_0), _fx_catch_0);
         *FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, *ht_table_0, tabsz_0) = *entry_0;
         found_free_slot_0 = true;
         FX_BREAK(_fx_catch_0);
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   if (!found_free_slot_0) {
      fx_str_t slit_0 = FX_MAKE_STR("cannot insert element (full Hashtable?!)");
      FX_CALL(_fx_F9make_FailE1S(&slit_0, &v_0), _fx_cleanup);
      FX_THROW(&v_0, true, _fx_cleanup);
   }
   *fx_result = tabsz_0 + 1;

_fx_cleanup: ;
   fx_free_exn(&v_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM4growv2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* self_0,
   int_ new_size_0,
   void* fx_fv)
{
   fx_arr_t ht_table_0 = {0};
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t v_0 = {0};
   fx_arr_t new_ht_table_0 = {0};
   fx_arr_t new_ht_index_0 = {0};
   int fx_status = 0;
   fx_copy_arr(&self_0->u.t.t5, &ht_table_0);
   _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&self_0->u.t.t0, &v_0);
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* dstptr_0 = 0;
   {
      const int_ shape_0[] = { new_size_0 };
      FX_CALL(
         fx_make_arr(1, shape_0, sizeof(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t),
            (fx_free_t)_fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t,
            (fx_copy_t)_fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, 0, &new_ht_table_0), _fx_cleanup);
   }
   dstptr_0 = (_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t*)new_ht_table_0.data;
   for (int_ i_0 = 0; i_0 < new_size_0; i_0++, dstptr_0++) {
      _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&v_0, dstptr_0);
   }
   FX_CALL(_fx_M7HashmapFM9makeindexA1i1i(new_size_0 * 2, &new_ht_index_0, 0), _fx_cleanup);
   int_ tabsz_0 = 0;
   int_ v_1 = self_0->u.t.t2;
   for (int_ j_0 = 0; j_0 < v_1; j_0++) {
      _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t v_2 = {0};
      FX_CHKIDX(FX_CHKIDX1(ht_table_0, 0, j_0), _fx_catch_0);
      if (FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, ht_table_0, j_0)->hv < 9223372036854775808ULL) {
         FX_CHKIDX(FX_CHKIDX1(ht_table_0, 0, j_0), _fx_catch_0);
         _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
            FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, ht_table_0, j_0), &v_2);
         int_ v_3;
         FX_CALL(
            _fx_M10C_gen_codeFM9add_fast_i4iA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_tRt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
               tabsz_0, &new_ht_index_0, &new_ht_table_0, &v_2, &v_3, 0), _fx_catch_0);
         tabsz_0 = v_3;
      }

   _fx_catch_0: ;
      _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&v_2);
      FX_CHECK_EXN(_fx_cleanup);
   }
   fx_arr_t* v_4 = &self_0->u.t.t4;
   FX_FREE_ARR(v_4);
   fx_copy_arr(&new_ht_index_0, v_4);
   fx_arr_t* v_5 = &self_0->u.t.t5;
   FX_FREE_ARR(v_5);
   fx_copy_arr(&new_ht_table_0, v_5);
   self_0->u.t.t2 = tabsz_0;
   self_0->u.t.t3 = 0;

_fx_cleanup: ;
   FX_FREE_ARR(&ht_table_0);
   _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&v_0);
   FX_FREE_ARR(&new_ht_table_0);
   FX_FREE_ARR(&new_ht_index_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM4growv2Nt10Hashmap__t2R9Ast__id_tii(
   struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t* self_0,
   int_ new_size_0,
   void* fx_fv)
{
   fx_arr_t ht_table_0 = {0};
   fx_arr_t new_ht_table_0 = {0};
   fx_arr_t new_ht_index_0 = {0};
   int fx_status = 0;
   fx_copy_arr(&self_0->u.t.t5, &ht_table_0);
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti v_0 = self_0->u.t.t0;
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti* dstptr_0 = 0;
   {
      const int_ shape_0[] = { new_size_0 };
      FX_CALL(fx_make_arr(1, shape_0, sizeof(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti), 0, 0, 0, &new_ht_table_0),
         _fx_cleanup);
   }
   dstptr_0 = (_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti*)new_ht_table_0.data;
   for (int_ i_0 = 0; i_0 < new_size_0; i_0++, dstptr_0++) {
      *dstptr_0 = v_0;
   }
   FX_CALL(_fx_M7HashmapFM9makeindexA1i1i(new_size_0 * 2, &new_ht_index_0, 0), _fx_cleanup);
   int_ tabsz_0 = 0;
   int_ v_1 = self_0->u.t.t2;
   for (int_ j_0 = 0; j_0 < v_1; j_0++) {
      FX_CHKIDX(FX_CHKIDX1(ht_table_0, 0, j_0), _fx_catch_0);
      if (FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, ht_table_0, j_0)->hv < 9223372036854775808ULL) {
         FX_CHKIDX(FX_CHKIDX1(ht_table_0, 0, j_0), _fx_catch_0);
         _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti v_2 = *FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, ht_table_0, j_0);
         int_ v_3;
         FX_CALL(
            _fx_M10C_gen_codeFM9add_fast_i4iA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_tiRt20Hashmap__hashentry_t2R9Ast__id_ti(
               tabsz_0, &new_ht_index_0, &new_ht_table_0, &v_2, &v_3, 0), _fx_catch_0);
         tabsz_0 = v_3;
      }

   _fx_catch_0: ;
      FX_CHECK_EXN(_fx_cleanup);
   }
   fx_arr_t* v_4 = &self_0->u.t.t4;
   FX_FREE_ARR(v_4);
   fx_copy_arr(&new_ht_index_0, v_4);
   fx_arr_t* v_5 = &self_0->u.t.t5;
   FX_FREE_ARR(v_5);
   fx_copy_arr(&new_ht_table_0, v_5);
   self_0->u.t.t2 = tabsz_0;
   self_0->u.t.t3 = 0;

_fx_cleanup: ;
   FX_FREE_ARR(&ht_table_0);
   FX_FREE_ARR(&new_ht_table_0);
   FX_FREE_ARR(&new_ht_index_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM9find_idx_Ta2i2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   struct _fx_Ta2i* fx_result,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   int fx_status = 0;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   uint64_t hv_0 = __fold_result___0 & 9223372036854775807ULL;
   fx_copy_arr(&self_0->u.t.t4, &v_0);
   int_ idxsz_0 = FX_ARR_SIZE(v_0, 0);
   uint64_t perturb_0 = hv_0;
   int_ found_0 = -1;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   int_ v_1 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_1; i_0++) {
      _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t entry_0 = {0};
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, self_0->u.t.t4, j_0);
      if (tidx_0 >= 2) {
         int_ v_2 = tidx_0 - 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, v_2), _fx_catch_0);
         _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
            FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, self_0->u.t.t5, v_2), &entry_0);
         bool t_0;
         if (entry_0.hv == hv_0) {
            _fx_R9Ast__id_t v_3 = entry_0.key;
            bool __fold_result___1 = true;
            bool t_1;
            if (v_3.m == k_0->m) {
               t_1 = __fold_result___1;
            }
            else {
               t_1 = false;
            }
            __fold_result___1 = t_1;
            bool t_2;
            if (v_3.i == k_0->i) {
               t_2 = __fold_result___1;
            }
            else {
               t_2 = false;
            }
            __fold_result___1 = t_2;
            bool t_3;
            if (v_3.j == k_0->j) {
               t_3 = __fold_result___1;
            }
            else {
               t_3 = false;
            }
            __fold_result___1 = t_3;
            t_0 = __fold_result___1;
         }
         else {
            t_0 = false;
         }
         if (t_0) {
            found_0 = tidx_0 - 2; FX_BREAK(_fx_catch_0);
         }
      }
      else if (tidx_0 == 0) {
         FX_BREAK(_fx_catch_0);
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&entry_0);
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_Ta2i tup_0 = { j_0, found_0 };
   *fx_result = tup_0;

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM9find_idx_Ta2i2Nt10Hashmap__t2R9Ast__id_tiR9Ast__id_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   struct _fx_Ta2i* fx_result,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   int fx_status = 0;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   uint64_t hv_0 = __fold_result___0 & 9223372036854775807ULL;
   fx_copy_arr(&self_0->u.t.t4, &v_0);
   int_ idxsz_0 = FX_ARR_SIZE(v_0, 0);
   uint64_t perturb_0 = hv_0;
   int_ found_0 = -1;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   int_ v_1 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_1; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, self_0->u.t.t4, j_0);
      if (tidx_0 >= 2) {
         int_ v_2 = tidx_0 - 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, v_2), _fx_catch_0);
         _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti entry_0 =
            *FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, self_0->u.t.t5, v_2);
         bool t_0;
         if (entry_0.hv == hv_0) {
            _fx_R9Ast__id_t v_3 = entry_0.key;
            bool __fold_result___1 = true;
            bool t_1;
            if (v_3.m == k_0->m) {
               t_1 = __fold_result___1;
            }
            else {
               t_1 = false;
            }
            __fold_result___1 = t_1;
            bool t_2;
            if (v_3.i == k_0->i) {
               t_2 = __fold_result___1;
            }
            else {
               t_2 = false;
            }
            __fold_result___1 = t_2;
            bool t_3;
            if (v_3.j == k_0->j) {
               t_3 = __fold_result___1;
            }
            else {
               t_3 = false;
            }
            __fold_result___1 = t_3;
            t_0 = __fold_result___1;
         }
         else {
            t_0 = false;
         }
         if (t_0) {
            found_0 = tidx_0 - 2; FX_BREAK(_fx_catch_0);
         }
      }
      else if (tidx_0 == 0) {
         FX_BREAK(_fx_catch_0);
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_Ta2i tup_0 = { j_0, found_0 };
   *fx_result = tup_0;

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   int_* fx_result,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   fx_arr_t v_1 = {0};
   _fx_N14C_form__cexp_t v_2 = 0;
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t v_3 = {0};
   fx_exn_t v_4 = {0};
   int fx_status = 0;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   uint64_t hv_0 = __fold_result___0 & 9223372036854775807ULL;
   fx_copy_arr(&self_0->u.t.t4, &v_0);
   int_ idxsz_0 = FX_ARR_SIZE(v_0, 0);
   if (self_0->u.t.t1 + 1 > idxsz_0 >> 1) {
      while (idxsz_0 < (self_0->u.t.t1 + 1) * 2) {
         idxsz_0 = idxsz_0 * 2;
      }
      FX_CALL(
         _fx_M10C_gen_codeFM4growv2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(self_0,
            fx_maxi(idxsz_0 / 2, self_0->u.t.t1 + 1), 0), _fx_cleanup);
   }
   uint64_t perturb_0 = hv_0;
   int_ found_0 = -1;
   int_ insert_idx_0 = -1;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   int_ v_5 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_5; i_0++) {
      _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t entry_0 = {0};
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, self_0->u.t.t4, j_0);
      if (tidx_0 >= 2) {
         int_ v_6 = tidx_0 - 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, v_6), _fx_catch_0);
         _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(
            FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, self_0->u.t.t5, v_6), &entry_0);
         bool t_0;
         if (entry_0.hv == hv_0) {
            _fx_R9Ast__id_t v_7 = entry_0.key;
            bool __fold_result___1 = true;
            bool t_1;
            if (v_7.m == k_0->m) {
               t_1 = __fold_result___1;
            }
            else {
               t_1 = false;
            }
            __fold_result___1 = t_1;
            bool t_2;
            if (v_7.i == k_0->i) {
               t_2 = __fold_result___1;
            }
            else {
               t_2 = false;
            }
            __fold_result___1 = t_2;
            bool t_3;
            if (v_7.j == k_0->j) {
               t_3 = __fold_result___1;
            }
            else {
               t_3 = false;
            }
            __fold_result___1 = t_3;
            t_0 = __fold_result___1;
         }
         else {
            t_0 = false;
         }
         if (t_0) {
            found_0 = tidx_0 - 2; FX_BREAK(_fx_catch_0);
         }
      }
      else if (tidx_0 == 0) {
         if (insert_idx_0 < 0) {
            insert_idx_0 = j_0;
         }
         FX_BREAK(_fx_catch_0);
      }
      else {
         bool t_4;
         if (tidx_0 == 1) {
            t_4 = insert_idx_0 < 0;
         }
         else {
            t_4 = false;
         }
         if (t_4) {
            insert_idx_0 = j_0;
         }
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&entry_0);
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   if (found_0 >= 0) {
      bool t_5;
      if (insert_idx_0 >= 0) {
         t_5 = insert_idx_0 != j_0;
      }
      else {
         t_5 = false;
      }
      if (t_5) {
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, insert_idx_0), _fx_cleanup);
         *FX_PTR_1D(int_, self_0->u.t.t4, insert_idx_0) = found_0 + 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_cleanup);
         *FX_PTR_1D(int_, self_0->u.t.t4, j_0) = 1;
      }
   }
   else if (insert_idx_0 >= 0) {
      found_0 = self_0->u.t.t3 - 1;
      if (found_0 >= 0) {
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, found_0), _fx_cleanup);
         self_0->u.t.t3 =
            (int_)
               (FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, self_0->u.t.t5, found_0)->hv &
                  9223372036854775807ULL);
      }
      else {
         found_0 = self_0->u.t.t2;
         self_0->u.t.t2 = self_0->u.t.t2 + 1;
         fx_copy_arr(&self_0->u.t.t5, &v_1);
         FX_CALL(_fx_F6assertv1B(found_0 < FX_ARR_SIZE(v_1, 0), 0), _fx_cleanup);
      }
      FX_COPY_PTR(self_0->u.t.t0.data, &v_2);
      _fx_make_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(hv_0, k_0, v_2, &v_3);
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, found_0), _fx_cleanup);
      _fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t* v_8 =
         FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, self_0->u.t.t5, found_0);
      _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(v_8);
      _fx_copy_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&v_3, v_8);
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, insert_idx_0), _fx_cleanup);
      *FX_PTR_1D(int_, self_0->u.t.t4, insert_idx_0) = found_0 + 2;
      self_0->u.t.t1 = self_0->u.t.t1 + 1;
   }
   else {
      fx_str_t slit_0 = FX_MAKE_STR("cannot insert element (full Hashtable?!)");
      FX_CALL(_fx_F9make_FailE1S(&slit_0, &v_4), _fx_cleanup);
      FX_THROW(&v_4, true, _fx_cleanup);
   }
   *fx_result = found_0;

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   FX_FREE_ARR(&v_1);
   if (v_2) {
      _fx_free_N14C_form__cexp_t(&v_2);
   }
   _fx_free_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t(&v_3);
   fx_free_exn(&v_4);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tiR9Ast__id_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_ti_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   int_* fx_result,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   fx_arr_t v_1 = {0};
   fx_exn_t v_2 = {0};
   int fx_status = 0;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   uint64_t hv_0 = __fold_result___0 & 9223372036854775807ULL;
   fx_copy_arr(&self_0->u.t.t4, &v_0);
   int_ idxsz_0 = FX_ARR_SIZE(v_0, 0);
   if (self_0->u.t.t1 + 1 > idxsz_0 >> 1) {
      while (idxsz_0 < (self_0->u.t.t1 + 1) * 2) {
         idxsz_0 = idxsz_0 * 2;
      }
      FX_CALL(_fx_M10C_gen_codeFM4growv2Nt10Hashmap__t2R9Ast__id_tii(self_0, fx_maxi(idxsz_0 / 2, self_0->u.t.t1 + 1), 0),
         _fx_cleanup);
   }
   uint64_t perturb_0 = hv_0;
   int_ found_0 = -1;
   int_ insert_idx_0 = -1;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   int_ v_3 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_3; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, self_0->u.t.t4, j_0);
      if (tidx_0 >= 2) {
         int_ v_4 = tidx_0 - 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, v_4), _fx_catch_0);
         _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti entry_0 =
            *FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, self_0->u.t.t5, v_4);
         bool t_0;
         if (entry_0.hv == hv_0) {
            _fx_R9Ast__id_t v_5 = entry_0.key;
            bool __fold_result___1 = true;
            bool t_1;
            if (v_5.m == k_0->m) {
               t_1 = __fold_result___1;
            }
            else {
               t_1 = false;
            }
            __fold_result___1 = t_1;
            bool t_2;
            if (v_5.i == k_0->i) {
               t_2 = __fold_result___1;
            }
            else {
               t_2 = false;
            }
            __fold_result___1 = t_2;
            bool t_3;
            if (v_5.j == k_0->j) {
               t_3 = __fold_result___1;
            }
            else {
               t_3 = false;
            }
            __fold_result___1 = t_3;
            t_0 = __fold_result___1;
         }
         else {
            t_0 = false;
         }
         if (t_0) {
            found_0 = tidx_0 - 2; FX_BREAK(_fx_catch_0);
         }
      }
      else if (tidx_0 == 0) {
         if (insert_idx_0 < 0) {
            insert_idx_0 = j_0;
         }
         FX_BREAK(_fx_catch_0);
      }
      else {
         bool t_4;
         if (tidx_0 == 1) {
            t_4 = insert_idx_0 < 0;
         }
         else {
            t_4 = false;
         }
         if (t_4) {
            insert_idx_0 = j_0;
         }
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   if (found_0 >= 0) {
      bool t_5;
      if (insert_idx_0 >= 0) {
         t_5 = insert_idx_0 != j_0;
      }
      else {
         t_5 = false;
      }
      if (t_5) {
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, insert_idx_0), _fx_cleanup);
         *FX_PTR_1D(int_, self_0->u.t.t4, insert_idx_0) = found_0 + 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_cleanup);
         *FX_PTR_1D(int_, self_0->u.t.t4, j_0) = 1;
      }
   }
   else if (insert_idx_0 >= 0) {
      found_0 = self_0->u.t.t3 - 1;
      if (found_0 >= 0) {
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, found_0), _fx_cleanup);
         self_0->u.t.t3 =
            (int_)(FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, self_0->u.t.t5, found_0)->hv & 9223372036854775807ULL);
      }
      else {
         found_0 = self_0->u.t.t2;
         self_0->u.t.t2 = self_0->u.t.t2 + 1;
         fx_copy_arr(&self_0->u.t.t5, &v_1);
         FX_CALL(_fx_F6assertv1B(found_0 < FX_ARR_SIZE(v_1, 0), 0), _fx_cleanup);
      }
      _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti v_6 = { hv_0, *k_0, self_0->u.t.t0.data };
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, found_0), _fx_cleanup);
      *FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, self_0->u.t.t5, found_0) = v_6;
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, insert_idx_0), _fx_cleanup);
      *FX_PTR_1D(int_, self_0->u.t.t4, insert_idx_0) = found_0 + 2;
      self_0->u.t.t1 = self_0->u.t.t1 + 1;
   }
   else {
      fx_str_t slit_0 = FX_MAKE_STR("cannot insert element (full Hashtable?!)");
      FX_CALL(_fx_F9make_FailE1S(&slit_0, &v_2), _fx_cleanup);
      FX_THROW(&v_2, true, _fx_cleanup);
   }
   *fx_result = found_0;

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   FX_FREE_ARR(&v_1);
   fx_free_exn(&v_2);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3addv3Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_tN14C_form__cexp_t(
   struct _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   struct _fx_N14C_form__cexp_t_data_t* d_0,
   void* fx_fv)
{
   int fx_status = 0;
   int_ idx_0;
   FX_CALL(
      _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_t(self_0, k_0, &idx_0, 0),
      _fx_cleanup);
   FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, idx_0), _fx_cleanup);
   _fx_N14C_form__cexp_t* v_0 =
      &FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, self_0->u.t.t5, idx_0)->data;
   _fx_free_N14C_form__cexp_t(v_0);
   FX_COPY_PTR(d_0, v_0);

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM9add_fast_i4iA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_tRt24Hashset__hashset_entry_t1R9Ast__id_t(
   int_ tabsz_0,
   fx_arr_t* ht_index_0,
   fx_arr_t* ht_table_0,
   struct _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t* entry_0,
   int_* fx_result,
   void* fx_fv)
{
   fx_exn_t v_0 = {0};
   int fx_status = 0;
   int_ idxsz_0 = FX_ARR_SIZE(*ht_index_0, 0);
   uint64_t hv_0 = entry_0->hv;
   uint64_t perturb_0 = hv_0;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   bool found_free_slot_0 = false;
   int_ v_1 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_1; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(*ht_index_0, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, *ht_index_0, j_0);
      if (tidx_0 == 0) {
         FX_CHKIDX(FX_CHKIDX1(*ht_index_0, 0, j_0), _fx_catch_0);
         *FX_PTR_1D(int_, *ht_index_0, j_0) = tabsz_0 + 2;
         FX_CHKIDX(FX_CHKIDX1(*ht_table_0, 0, tabsz_0), _fx_catch_0);
         *FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, *ht_table_0, tabsz_0) = *entry_0;
         found_free_slot_0 = true;
         FX_BREAK(_fx_catch_0);
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   if (!found_free_slot_0) {
      fx_str_t slit_0 = FX_MAKE_STR("cannot insert element (full Hashtable?!)");
      FX_CALL(_fx_F9make_FailE1S(&slit_0, &v_0), _fx_cleanup);
      FX_THROW(&v_0, true, _fx_cleanup);
   }
   *fx_result = tabsz_0 + 1;

_fx_cleanup: ;
   fx_free_exn(&v_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM4growv2Nt10Hashset__t1R9Ast__id_ti(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* self_0,
   int_ new_size_0,
   void* fx_fv)
{
   fx_arr_t ht_table_0 = {0};
   fx_arr_t new_ht_table_0 = {0};
   fx_arr_t new_ht_index_0 = {0};
   int fx_status = 0;
   fx_copy_arr(&self_0->u.t.t5, &ht_table_0);
   _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t v_0 = self_0->u.t.t0;
   _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t* dstptr_0 = 0;
   {
      const int_ shape_0[] = { new_size_0 };
      FX_CALL(fx_make_arr(1, shape_0, sizeof(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t), 0, 0, 0, &new_ht_table_0),
         _fx_cleanup);
   }
   dstptr_0 = (_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t*)new_ht_table_0.data;
   for (int_ i_0 = 0; i_0 < new_size_0; i_0++, dstptr_0++) {
      *dstptr_0 = v_0;
   }
   FX_CALL(_fx_M7HashsetFM9makeindexA1i1i(new_size_0 * 2, &new_ht_index_0, 0), _fx_cleanup);
   int_ tabsz_0 = 0;
   int_ v_1 = self_0->u.t.t2;
   for (int_ j_0 = 0; j_0 < v_1; j_0++) {
      FX_CHKIDX(FX_CHKIDX1(ht_table_0, 0, j_0), _fx_catch_0);
      if (FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, ht_table_0, j_0)->hv < 9223372036854775808ULL) {
         FX_CHKIDX(FX_CHKIDX1(ht_table_0, 0, j_0), _fx_catch_0);
         _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t v_2 =
            *FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, ht_table_0, j_0);
         int_ v_3;
         FX_CALL(
            _fx_M10C_gen_codeFM9add_fast_i4iA1iA1Rt24Hashset__hashset_entry_t1R9Ast__id_tRt24Hashset__hashset_entry_t1R9Ast__id_t(
               tabsz_0, &new_ht_index_0, &new_ht_table_0, &v_2, &v_3, 0), _fx_catch_0);
         tabsz_0 = v_3;
      }

   _fx_catch_0: ;
      FX_CHECK_EXN(_fx_cleanup);
   }
   fx_arr_t* v_4 = &self_0->u.t.t4;
   FX_FREE_ARR(v_4);
   fx_copy_arr(&new_ht_index_0, v_4);
   fx_arr_t* v_5 = &self_0->u.t.t5;
   FX_FREE_ARR(v_5);
   fx_copy_arr(&new_ht_table_0, v_5);
   self_0->u.t.t2 = tabsz_0;
   self_0->u.t.t3 = 0;

_fx_cleanup: ;
   FX_FREE_ARR(&ht_table_0);
   FX_FREE_ARR(&new_ht_table_0);
   FX_FREE_ARR(&new_ht_index_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   uint64_t hv_0,
   struct _fx_Ta2i* fx_result,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   int fx_status = 0;
   fx_copy_arr(&self_0->u.t.t4, &v_0);
   int_ idxsz_0 = FX_ARR_SIZE(v_0, 0);
   uint64_t perturb_0 = hv_0;
   int_ found_0 = -1;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   int_ v_1 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_1; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, self_0->u.t.t4, j_0);
      if (tidx_0 >= 2) {
         int_ v_2 = tidx_0 - 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, v_2), _fx_catch_0);
         _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t entry_0 =
            *FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, self_0->u.t.t5, v_2);
         bool t_0;
         if (entry_0.hv == hv_0) {
            _fx_R9Ast__id_t v_3 = entry_0.key;
            bool __fold_result___0 = true;
            bool t_1;
            if (v_3.m == k_0->m) {
               t_1 = __fold_result___0;
            }
            else {
               t_1 = false;
            }
            __fold_result___0 = t_1;
            bool t_2;
            if (v_3.i == k_0->i) {
               t_2 = __fold_result___0;
            }
            else {
               t_2 = false;
            }
            __fold_result___0 = t_2;
            bool t_3;
            if (v_3.j == k_0->j) {
               t_3 = __fold_result___0;
            }
            else {
               t_3 = false;
            }
            __fold_result___0 = t_3;
            t_0 = __fold_result___0;
         }
         else {
            t_0 = false;
         }
         if (t_0) {
            found_0 = tidx_0 - 2; FX_BREAK(_fx_catch_0);
         }
      }
      else if (tidx_0 == 0) {
         FX_BREAK(_fx_catch_0);
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_Ta2i tup_0 = { j_0, found_0 };
   *fx_result = tup_0;

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3memB2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   _fx_Ta2i v_0;
   FX_CALL(
      _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(self_0, k_0,
         __fold_result___0 & 9223372036854775807ULL, &v_0, 0), _fx_cleanup);
   *fx_result = v_0.t1 >= 0;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   uint64_t hv_0,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   fx_arr_t v_1 = {0};
   fx_exn_t v_2 = {0};
   int fx_status = 0;
   fx_copy_arr(&self_0->u.t.t4, &v_0);
   int_ idxsz_0 = FX_ARR_SIZE(v_0, 0);
   if (self_0->u.t.t1 + 1 > idxsz_0 >> 1) {
      while (idxsz_0 < (self_0->u.t.t1 + 1) * 2) {
         idxsz_0 = idxsz_0 * 2;
      }
      FX_CALL(_fx_M10C_gen_codeFM4growv2Nt10Hashset__t1R9Ast__id_ti(self_0, fx_maxi(idxsz_0 / 2, self_0->u.t.t1 + 1), 0),
         _fx_cleanup);
   }
   uint64_t perturb_0 = hv_0;
   int_ found_0 = -1;
   int_ insert_idx_0 = -1;
   int_ j_0 = (int_)hv_0 & (idxsz_0 - 1);
   int_ v_3 = idxsz_0 + 14;
   for (int_ i_0 = 0; i_0 < v_3; i_0++) {
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_catch_0);
      int_ tidx_0 = *FX_PTR_1D(int_, self_0->u.t.t4, j_0);
      if (tidx_0 >= 2) {
         int_ v_4 = tidx_0 - 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, v_4), _fx_catch_0);
         _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t entry_0 =
            *FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, self_0->u.t.t5, v_4);
         bool t_0;
         if (entry_0.hv == hv_0) {
            _fx_R9Ast__id_t v_5 = entry_0.key;
            bool __fold_result___0 = true;
            bool t_1;
            if (v_5.m == k_0->m) {
               t_1 = __fold_result___0;
            }
            else {
               t_1 = false;
            }
            __fold_result___0 = t_1;
            bool t_2;
            if (v_5.i == k_0->i) {
               t_2 = __fold_result___0;
            }
            else {
               t_2 = false;
            }
            __fold_result___0 = t_2;
            bool t_3;
            if (v_5.j == k_0->j) {
               t_3 = __fold_result___0;
            }
            else {
               t_3 = false;
            }
            __fold_result___0 = t_3;
            t_0 = __fold_result___0;
         }
         else {
            t_0 = false;
         }
         if (t_0) {
            found_0 = tidx_0 - 2; FX_BREAK(_fx_catch_0);
         }
      }
      else if (tidx_0 == 0) {
         if (insert_idx_0 < 0) {
            insert_idx_0 = j_0;
         }
         FX_BREAK(_fx_catch_0);
      }
      else {
         bool t_4;
         if (tidx_0 == 1) {
            t_4 = insert_idx_0 < 0;
         }
         else {
            t_4 = false;
         }
         if (t_4) {
            insert_idx_0 = j_0;
         }
      }
      perturb_0 = perturb_0 >> 5;
      j_0 = (int_)((uint64_t)(j_0 * 5 + 1) + perturb_0) & (idxsz_0 - 1);

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   if (found_0 >= 0) {
      bool t_5;
      if (insert_idx_0 >= 0) {
         t_5 = insert_idx_0 != j_0;
      }
      else {
         t_5 = false;
      }
      if (t_5) {
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, insert_idx_0), _fx_cleanup);
         *FX_PTR_1D(int_, self_0->u.t.t4, insert_idx_0) = found_0 + 2;
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, j_0), _fx_cleanup);
         *FX_PTR_1D(int_, self_0->u.t.t4, j_0) = 1;
      }
   }
   else if (insert_idx_0 >= 0) {
      found_0 = self_0->u.t.t3 - 1;
      if (found_0 >= 0) {
         FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, found_0), _fx_cleanup);
         self_0->u.t.t3 =
            (int_)
               (FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, self_0->u.t.t5, found_0)->hv & 9223372036854775807ULL);
      }
      else {
         found_0 = self_0->u.t.t2;
         self_0->u.t.t2 = self_0->u.t.t2 + 1;
         fx_copy_arr(&self_0->u.t.t5, &v_1);
         FX_CALL(_fx_F6assertv1B(found_0 < FX_ARR_SIZE(v_1, 0), 0), _fx_cleanup);
      }
      _fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t v_6 = { hv_0, *k_0 };
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t5, 0, found_0), _fx_cleanup);
      *FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, self_0->u.t.t5, found_0) = v_6;
      FX_CHKIDX(FX_CHKIDX1(self_0->u.t.t4, 0, insert_idx_0), _fx_cleanup);
      *FX_PTR_1D(int_, self_0->u.t.t4, insert_idx_0) = found_0 + 2;
      self_0->u.t.t1 = self_0->u.t.t1 + 1;
   }
   else {
      fx_str_t slit_0 = FX_MAKE_STR("cannot insert element (full Hashtable?!)");
      FX_CALL(_fx_F9make_FailE1S(&slit_0, &v_2), _fx_cleanup);
      FX_THROW(&v_2, true, _fx_cleanup);
   }

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   FX_FREE_ARR(&v_1);
   fx_free_exn(&v_2);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM3addv2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* self_0,
   struct _fx_R9Ast__id_t* k_0,
   void* fx_fv)
{
   int fx_status = 0;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   FX_CALL(
      _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(self_0, k_0, __fold_result___0 & 9223372036854775807ULL,
         0), _fx_cleanup);

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM5unionv2Nt10Hashset__t1R9Ast__id_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* self_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* b_0,
   void* fx_fv)
{
   fx_arr_t table_0 = {0};
   int fx_status = 0;
   fx_copy_arr(&b_0->u.t.t5, &table_0);
   int_ v_0 = b_0->u.t.t2;
   for (int_ j_0 = 0; j_0 < v_0; j_0++) {
      FX_CHKIDX(FX_CHKIDX1(table_0, 0, j_0), _fx_catch_0);
      if (FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, table_0, j_0)->hv < 9223372036854775808ULL) {
         FX_CHKIDX(FX_CHKIDX1(table_0, 0, j_0), _fx_catch_0);
         _fx_R9Ast__id_t v_1 = FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, table_0, j_0)->key;
         FX_CHKIDX(FX_CHKIDX1(table_0, 0, j_0), _fx_catch_0);
         FX_CALL(
            _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(self_0, &v_1,
               FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, table_0, j_0)->hv, 0), _fx_catch_0);
      }

   _fx_catch_0: ;
      FX_CHECK_EXN(_fx_cleanup);
   }

_fx_cleanup: ;
   FX_FREE_ARR(&table_0);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8find_optNt6option1R9Ast__id_t2Rt6Map__t2R9Ast__id_tR9Ast__id_tR9Ast__id_t(
   struct _fx_Rt6Map__t2R9Ast__id_tR9Ast__id_t* m_0,
   struct _fx_R9Ast__id_t* x_0,
   struct _fx_Nt6option1R9Ast__id_t* fx_result,
   void* fx_fv)
{
   _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t v_0 = 0;
   _fx_FPi2R9Ast__id_tR9Ast__id_t v_1 = {0};
   _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t t_0 = 0;
   _fx_FPi2R9Ast__id_tR9Ast__id_t cmp_0 = {0};
   int fx_status = 0;
   FX_COPY_PTR(m_0->root, &v_0);
   FX_COPY_FP(&m_0->cmp, &v_1);
   _fx_Nt6option1R9Ast__id_t result_0 = {0};
   FX_COPY_PTR(v_0, &t_0);
   _fx_R9Ast__id_t xk_0 = *x_0;
   FX_COPY_FP(&v_1, &cmp_0);
   for (;;) {
      _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t t_1 = 0;
      _fx_FPi2R9Ast__id_tR9Ast__id_t cmp_1 = {0};
      FX_COPY_PTR(t_0, &t_1);
      _fx_R9Ast__id_t xk_1 = xk_0;
      FX_COPY_FP(&cmp_0, &cmp_1);
      if ((t_1 != 0) + 1 == 2) {
         _fx_T5N12Map__color_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_tR9Ast__id_tR9Ast__id_tNt11Map__tree_t2R9Ast__id_tR9Ast__id_t*
            vcase_0 = &t_1->u.Node;
         int_ c_0;
         FX_CALL(cmp_1.fp(&xk_1, &vcase_0->t2, &c_0, cmp_1.fcv), _fx_catch_0);
         if (c_0 < 0) {
            _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t* l_0 = &vcase_0->t1;
            _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&t_0);
            FX_COPY_PTR(*l_0, &t_0);
            xk_0 = xk_1;
            FX_FREE_FP(&cmp_0);
            FX_COPY_FP(&cmp_1, &cmp_0);
         }
         else if (c_0 > 0) {
            _fx_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t* r_0 = &vcase_0->t4;
            _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&t_0);
            FX_COPY_PTR(*r_0, &t_0);
            xk_0 = xk_1;
            FX_FREE_FP(&cmp_0);
            FX_COPY_FP(&cmp_1, &cmp_0);
         }
         else {
            _fx_Nt6option1R9Ast__id_t result_1;
            _fx_M10C_gen_codeFM4SomeNt6option1R9Ast__id_t1R9Ast__id_t(&vcase_0->t3, &result_1);
            result_0 = result_1;
            FX_BREAK(_fx_catch_0);
         }

      _fx_catch_0: ;
      }
      else {
         result_0 = _fx_g18C_gen_code__None3_; FX_BREAK(_fx_catch_1);  _fx_catch_1: ;
      }
      FX_CHECK_EXN(_fx_catch_2);

   _fx_catch_2: ;
      FX_FREE_FP(&cmp_1);
      if (t_1) {
         _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&t_1);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = result_0;

_fx_cleanup: ;
   if (v_0) {
      _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&v_0);
   }
   FX_FREE_FP(&v_1);
   if (t_0) {
      _fx_free_Nt11Map__tree_t2R9Ast__id_tR9Ast__id_t(&t_0);
   }
   FX_FREE_FP(&cmp_0);
   return fx_status;
}

FX_EXTERN_C void _fx_M10C_gen_codeFM13BlockKind_FunN24C_gen_code__block_kind_t1R9Ast__id_t(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_N24C_gen_code__block_kind_t* fx_result)
{
   fx_result->tag = 2;
   fx_result->u.BlockKind_Fun = *arg0;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM10count_ktypv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__ktyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv)
{
   int fx_status = 0;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM20find_single_use_valsNt10Hashset__t1R9Ast__id_t1LN14K_form__kexp_t(
   struct _fx_LN14K_form__kexp_t_data_t* topcode_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t** fx_result,
   void* fx_fv)
{
   fx_arr_t v_0 = {0};
   fx_arr_t v_1 = {0};
   _fx_Nt10Hashmap__t2R9Ast__id_ti count_map_arg_0 = 0;
   _fx_rNt10Hashmap__t2R9Ast__id_ti count_map_ref_0 = 0;
   _fx_Nt10Hashset__t1R9Ast__id_t decl_const_vals_arg_0 = 0;
   _fx_rNt10Hashset__t1R9Ast__id_t decl_const_vals_ref_0 = 0;
   _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t count_atom_0 = {0};
   _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t count_kexp_0 = {0};
   _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t count_ktyp_0 = {0};
   _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t v_2 = 0;
   _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t v_3 = 0;
   _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t v_4 = 0;
   _fx_R22K_form__k_fold_callb_t count_callb_0 = {0};
   _fx_Nt10Hashset__t1R9Ast__id_t u1_vals_0 = 0;
   fx_arr_t table_0 = {0};
   int fx_status = 0;
   int_ size_0 = 8;
   while (size_0 < 1024) {
      size_0 = size_0 * 2;
   }
   int_ idxsize_0 = size_0 * 2;
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti entry0_0 = { 0ULL, _fx_g9Ast__noid, 0 };
   FX_CALL(_fx_M7HashmapFM9makeindexA1i1i(idxsize_0, &v_0, 0), _fx_cleanup);
   _fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti* dstptr_0 = 0;
   int_ n_0 = size_0;
   {
      const int_ shape_0[] = { n_0 };
      FX_CALL(fx_make_arr(1, shape_0, sizeof(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti), 0, 0, 0, &v_1), _fx_cleanup);
   }
   dstptr_0 = (_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti*)v_1.data;
   for (int_ i_0 = 0; i_0 < n_0; i_0++, dstptr_0++) {
      *dstptr_0 = entry0_0;
   }
   FX_CALL(
      _fx_M10C_gen_codeFM1tNt10Hashmap__t2R9Ast__id_ti6Rt20Hashmap__hashentry_t2R9Ast__id_tiiiiA1iA1Rt20Hashmap__hashentry_t2R9Ast__id_ti(
         &entry0_0, 0, 0, 0, &v_0, &v_1, &count_map_arg_0), _fx_cleanup);
   FX_CALL(_fx_make_rNt10Hashmap__t2R9Ast__id_ti(count_map_arg_0, &count_map_ref_0), _fx_cleanup);
   FX_CALL(_fx_M3AstFM16empty_id_hashsetNt10Hashset__t1RM4id_t1i(1024, &decl_const_vals_arg_0, 0), _fx_cleanup);
   FX_CALL(_fx_make_rNt10Hashset__t1R9Ast__id_t(decl_const_vals_arg_0, &decl_const_vals_ref_0), _fx_cleanup);
   _fx_Nt10Hashset__t1R9Ast__id_t* decl_const_vals_0 = &decl_const_vals_ref_0->data;
   _fx_M10C_gen_codeFM7make_fpFPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t2rNt10Hashmap__t2R9Ast__id_tirNt10Hashset__t1R9Ast__id_t(
      count_map_ref_0, decl_const_vals_ref_0, &count_atom_0);
   _fx_M10C_gen_codeFM7make_fpFPv2N14K_form__kexp_tR22K_form__k_fold_callb_t2rNt10Hashmap__t2R9Ast__id_tirNt10Hashset__t1R9Ast__id_t(
      count_map_ref_0, decl_const_vals_ref_0, &count_kexp_0);
   _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t count_ktyp_fp_0 =
      { _fx_M10C_gen_codeFM10count_ktypv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t, 0 };
   FX_COPY_FP(&count_ktyp_fp_0, &count_ktyp_0);
   FX_CALL(
      _fx_M10C_gen_codeFM4SomeNt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
         &count_ktyp_0, &v_2), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM4SomeNt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
         &count_kexp_0, &v_3), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM4SomeNt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
         &count_atom_0, &v_4), _fx_cleanup);
   _fx_make_R22K_form__k_fold_callb_t(v_2, v_3, v_4, &count_callb_0);
   _fx_LN14K_form__kexp_t lst_0 = topcode_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_N14K_form__kexp_t e_0 = lst_0->hd;
      FX_CALL(count_kexp_0.fp(e_0, &count_callb_0, count_kexp_0.fcv), _fx_catch_0);

   _fx_catch_0: ;
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_CALL(_fx_M3AstFM16empty_id_hashsetNt10Hashset__t1RM4id_t1i((*decl_const_vals_0)->u.t.t1, &u1_vals_0, 0), _fx_cleanup);
   fx_copy_arr(&(*decl_const_vals_0)->u.t.t5, &table_0);
   int_ v_5 = (*decl_const_vals_0)->u.t.t2;
   for (int_ j_0 = 0; j_0 < v_5; j_0++) {
      FX_CHKIDX(FX_CHKIDX1(table_0, 0, j_0), _fx_catch_1);
      if (FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, table_0, j_0)->hv < 9223372036854775808ULL) {
         FX_CHKIDX(FX_CHKIDX1(table_0, 0, j_0), _fx_catch_1);
         _fx_R9Ast__id_t v_6 = FX_PTR_1D(_fx_Rt24Hashset__hashset_entry_t1R9Ast__id_t, table_0, j_0)->key;
         FX_CALL(
            _fx_M10C_gen_codeFM10__lambda__v3R9Ast__id_trNt10Hashmap__t2R9Ast__id_tiNt10Hashset__t1R9Ast__id_t(&v_6,
               count_map_ref_0, u1_vals_0, 0), _fx_catch_1);
      }

   _fx_catch_1: ;
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(u1_vals_0, fx_result);

_fx_cleanup: ;
   FX_FREE_ARR(&v_0);
   FX_FREE_ARR(&v_1);
   if (count_map_arg_0) {
      _fx_free_Nt10Hashmap__t2R9Ast__id_ti(&count_map_arg_0);
   }
   if (count_map_ref_0) {
      _fx_free_rNt10Hashmap__t2R9Ast__id_ti(&count_map_ref_0);
   }
   if (decl_const_vals_arg_0) {
      _fx_free_Nt10Hashset__t1R9Ast__id_t(&decl_const_vals_arg_0);
   }
   if (decl_const_vals_ref_0) {
      _fx_free_rNt10Hashset__t1R9Ast__id_t(&decl_const_vals_ref_0);
   }
   FX_FREE_FP(&count_atom_0);
   FX_FREE_FP(&count_kexp_0);
   FX_FREE_FP(&count_ktyp_0);
   if (v_2) {
      _fx_free_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(&v_2);
   }
   if (v_3) {
      _fx_free_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(&v_3);
   }
   if (v_4) {
      _fx_free_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(&v_4);
   }
   _fx_free_R22K_form__k_fold_callb_t(&count_callb_0);
   if (u1_vals_0) {
      _fx_free_Nt10Hashset__t1R9Ast__id_t(&u1_vals_0);
   }
   FX_FREE_ARR(&table_0);
   return fx_status;
}

static int _fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv)
{
   int fx_status = 0;
   _fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t* cv_0 =
      (_fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t*)fx_fv;
   _fx_Nt10Hashmap__t2R9Ast__id_ti* count_map_0 = &cv_0->t0->data;
   if (a_0->tag == 1) {
      _fx_R9Ast__id_t* i_0 = &a_0->u.AtomId;
      uint64_t __fold_result___0 = 14695981039346656037ULL;
      uint64_t h_0 = __fold_result___0 ^ ((uint64_t)i_0->m ^ 14695981039346656037ULL);
      __fold_result___0 = h_0 * 1099511628211ULL;
      uint64_t h_1 = __fold_result___0 ^ ((uint64_t)i_0->i ^ 14695981039346656037ULL);
      __fold_result___0 = h_1 * 1099511628211ULL;
      uint64_t h_2 = __fold_result___0 ^ ((uint64_t)i_0->j ^ 14695981039346656037ULL);
      __fold_result___0 = h_2 * 1099511628211ULL;
      _fx_Ta2i v_0;
      FX_CALL(
         _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(cv_0->t1->data, i_0,
            __fold_result___0 & 9223372036854775807ULL, &v_0, 0), _fx_catch_0);
      if (v_0.t1 >= 0) {
         int_ idx_0;
         FX_CALL(_fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tiR9Ast__id_t(*count_map_0, i_0, &idx_0, 0),
            _fx_catch_0);
         FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, idx_0), _fx_catch_0);
         FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, idx_0), _fx_catch_0);
         FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, idx_0)->data =
            FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, idx_0)->data + 1;
      }

   _fx_catch_0: ;
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t2rNt10Hashmap__t2R9Ast__id_tirNt10Hashset__t1R9Ast__id_t(
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t* fx_result)
{
   FX_MAKE_FP_IMPL_START(_fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t,
      _fx_free_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t,
      _fx_M10C_gen_codeFM10count_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   return 0;
}

static int _fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv)
{
   _fx_N14K_form__kexp_t e_1 = 0;
   _fx_R22K_form__k_fold_callb_t callb_1 = {0};
   int fx_status = 0;
   _fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t* cv_0 =
      (_fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t*)fx_fv;
   _fx_Nt10Hashmap__t2R9Ast__id_ti* count_map_0 = &cv_0->t0->data;
   _fx_Nt10Hashset__t1R9Ast__id_t* decl_const_vals_0 = &cv_0->t1->data;
   FX_COPY_PTR(e_0, &e_1);
   _fx_copy_R22K_form__k_fold_callb_t(callb_0, &callb_1);
   for (;;) {
      _fx_N14K_form__kexp_t e_2 = 0;
      _fx_R22K_form__k_fold_callb_t callb_2 = {0};
      FX_COPY_PTR(e_1, &e_2);
      _fx_copy_R22K_form__k_fold_callb_t(&callb_1, &callb_2);
      int tag_0 = FX_REC_VARIANT_TAG(e_2);
      if (tag_0 == 31) {
         _fx_R17K_form__kdefval_t v_0 = {0};
         _fx_R16Ast__val_flags_t kv_flags_0 = {0};
         _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t* vcase_0 = &e_2->u.KDefVal;
         _fx_N14K_form__kexp_t e1_0 = vcase_0->t1;
         _fx_R9Ast__id_t* k_0 = &vcase_0->t0;
         FX_CALL(_fx_M6K_formFM8get_kvalRM9kdefval_t2R9Ast__id_tR10Ast__loc_t(k_0, &vcase_0->t2, &v_0, 0), _fx_catch_0);
         _fx_copy_R16Ast__val_flags_t(&v_0.kv_flags, &kv_flags_0);
         bool good_temp_0;
         if (kv_flags_0.val_flag_tempref) {
            good_temp_0 = true;
         }
         else {
            good_temp_0 = kv_flags_0.val_flag_temp;
         }
         bool v_1;
         if (good_temp_0) {
            FX_CALL(_fx_M15K_remove_unusedFM9pure_kexpB1N14K_form__kexp_t(e1_0, &v_1, 0), _fx_catch_0);
         }
         else {
            v_1 = false;
         }
         if (v_1) {
            uint64_t __fold_result___0 = 14695981039346656037ULL;
            uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
            __fold_result___0 = h_0 * 1099511628211ULL;
            uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
            __fold_result___0 = h_1 * 1099511628211ULL;
            uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
            __fold_result___0 = h_2 * 1099511628211ULL;
            FX_CALL(
               _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*decl_const_vals_0, k_0,
                  __fold_result___0 & 9223372036854775807ULL, 0), _fx_catch_0);
         }
         _fx_free_N14K_form__kexp_t(&e_1);
         FX_COPY_PTR(e1_0, &e_1);
         _fx_free_R22K_form__k_fold_callb_t(&callb_1);
         _fx_copy_R22K_form__k_fold_callb_t(&callb_2, &callb_1);

      _fx_catch_0: ;
         _fx_free_R16Ast__val_flags_t(&kv_flags_0);
         _fx_free_R17K_form__kdefval_t(&v_0);
      }
      else if (tag_0 == 12) {
         _fx_N14K_form__atom_t v_2 = {0};
         _fx_M6K_formFM6AtomIdN14K_form__atom_t1R9Ast__id_t(&e_2->u.KExpCall.t0, &v_2);
         if (v_2.tag == 1) {
            _fx_R9Ast__id_t* i_0 = &v_2.u.AtomId;
            uint64_t __fold_result___1 = 14695981039346656037ULL;
            uint64_t h_3 = __fold_result___1 ^ ((uint64_t)i_0->m ^ 14695981039346656037ULL);
            __fold_result___1 = h_3 * 1099511628211ULL;
            uint64_t h_4 = __fold_result___1 ^ ((uint64_t)i_0->i ^ 14695981039346656037ULL);
            __fold_result___1 = h_4 * 1099511628211ULL;
            uint64_t h_5 = __fold_result___1 ^ ((uint64_t)i_0->j ^ 14695981039346656037ULL);
            __fold_result___1 = h_5 * 1099511628211ULL;
            _fx_Ta2i v_3;
            FX_CALL(
               _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*decl_const_vals_0, i_0,
                  __fold_result___1 & 9223372036854775807ULL, &v_3, 0), _fx_catch_1);
            if (v_3.t1 >= 0) {
               int_ idx_0;
               FX_CALL(
                  _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tiR9Ast__id_t(*count_map_0, i_0, &idx_0, 0),
                  _fx_catch_1);
               FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, idx_0), _fx_catch_1);
               FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, idx_0), _fx_catch_1);
               FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, idx_0)->data =
                  FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, idx_0)->data + 1;
            }

         _fx_catch_1: ;
         }
         FX_CHECK_EXN(_fx_catch_2);
         FX_CALL(_fx_M6K_formFM9fold_kexpv2N14K_form__kexp_tRM14k_fold_callb_t(e_2, &callb_2, 0), _fx_catch_2);
         FX_BREAK(_fx_catch_2);

      _fx_catch_2: ;
         _fx_free_N14K_form__atom_t(&v_2);
      }
      else if (tag_0 == 13) {
         _fx_N14K_form__atom_t v_4 = {0};
         _fx_M6K_formFM6AtomIdN14K_form__atom_t1R9Ast__id_t(&e_2->u.KExpICall.t0, &v_4);
         if (v_4.tag == 1) {
            _fx_R9Ast__id_t* i_1 = &v_4.u.AtomId;
            uint64_t __fold_result___2 = 14695981039346656037ULL;
            uint64_t h_6 = __fold_result___2 ^ ((uint64_t)i_1->m ^ 14695981039346656037ULL);
            __fold_result___2 = h_6 * 1099511628211ULL;
            uint64_t h_7 = __fold_result___2 ^ ((uint64_t)i_1->i ^ 14695981039346656037ULL);
            __fold_result___2 = h_7 * 1099511628211ULL;
            uint64_t h_8 = __fold_result___2 ^ ((uint64_t)i_1->j ^ 14695981039346656037ULL);
            __fold_result___2 = h_8 * 1099511628211ULL;
            _fx_Ta2i v_5;
            FX_CALL(
               _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*decl_const_vals_0, i_1,
                  __fold_result___2 & 9223372036854775807ULL, &v_5, 0), _fx_catch_3);
            if (v_5.t1 >= 0) {
               int_ idx_1;
               FX_CALL(
                  _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tiR9Ast__id_t(*count_map_0, i_1, &idx_1, 0),
                  _fx_catch_3);
               FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, idx_1), _fx_catch_3);
               FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, idx_1), _fx_catch_3);
               FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, idx_1)->data =
                  FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, idx_1)->data + 1;
            }

         _fx_catch_3: ;
         }
         FX_CHECK_EXN(_fx_catch_4);
         FX_CALL(_fx_M6K_formFM9fold_kexpv2N14K_form__kexp_tRM14k_fold_callb_t(e_2, &callb_2, 0), _fx_catch_4);
         FX_BREAK(_fx_catch_4);

      _fx_catch_4: ;
         _fx_free_N14K_form__atom_t(&v_4);
      }
      else {
         FX_CALL(_fx_M6K_formFM9fold_kexpv2N14K_form__kexp_tRM14k_fold_callb_t(e_2, &callb_2, 0), _fx_catch_5);
         FX_BREAK(_fx_catch_5);

      _fx_catch_5: ;
      }
      FX_CHECK_EXN(_fx_catch_6);

   _fx_catch_6: ;
      _fx_free_R22K_form__k_fold_callb_t(&callb_2);
      if (e_2) {
         _fx_free_N14K_form__kexp_t(&e_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }

_fx_cleanup: ;
   if (e_1) {
      _fx_free_N14K_form__kexp_t(&e_1);
   }
   _fx_free_R22K_form__k_fold_callb_t(&callb_1);
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPv2N14K_form__kexp_tR22K_form__k_fold_callb_t2rNt10Hashmap__t2R9Ast__id_tirNt10Hashset__t1R9Ast__id_t(
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t* fx_result)
{
   FX_MAKE_FP_IMPL_START(_fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t,
      _fx_free_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t,
      _fx_M10C_gen_codeFM10count_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   return 0;
}

static int _fx_M10C_gen_codeFM10__lambda__v3R9Ast__id_trNt10Hashmap__t2R9Ast__id_tiNt10Hashset__t1R9Ast__id_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_ti_data_t* count_map_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1_vals_0,
   void* fx_fv)
{
   int fx_status = 0;
   _fx_Nt10Hashmap__t2R9Ast__id_ti* count_map_0 = &count_map_ref_0->data;
   _fx_Ta2i v_0;
   FX_CALL(_fx_M10C_gen_codeFM9find_idx_Ta2i2Nt10Hashmap__t2R9Ast__id_tiR9Ast__id_t(*count_map_0, i_0, &v_0, 0), _fx_cleanup);
   int_ j_0 = v_0.t1;
   _fx_Nt6option1i v_1;
   if (j_0 >= 0) {
      FX_CHKIDX(FX_CHKIDX1((*count_map_0)->u.t.t5, 0, j_0), _fx_cleanup);
      _fx_M10C_gen_codeFM4SomeNt6option1i1i(
         FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_ti, (*count_map_0)->u.t.t5, j_0)->data, &v_1);
   }
   else {
      v_1 = _fx_g18C_gen_code__None4_;
   }
   if (v_1.tag == 2) {
      if (v_1.u.Some == 1) {
         uint64_t __fold_result___0 = 14695981039346656037ULL;
         uint64_t h_0 = __fold_result___0 ^ ((uint64_t)i_0->m ^ 14695981039346656037ULL);
         __fold_result___0 = h_0 * 1099511628211ULL;
         uint64_t h_1 = __fold_result___0 ^ ((uint64_t)i_0->i ^ 14695981039346656037ULL);
         __fold_result___0 = h_1 * 1099511628211ULL;
         uint64_t h_2 = __fold_result___0 ^ ((uint64_t)i_0->j ^ 14695981039346656037ULL);
         __fold_result___0 = h_2 * 1099511628211ULL;
         FX_CALL(
            _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(u1_vals_0, i_0,
               __fold_result___0 & 9223372036854775807ULL, 0), _fx_catch_0);

      _fx_catch_0: ;
         goto _fx_endmatch_0;
      }
   }

_fx_endmatch_0: ;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM11occurs_ktypv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__ktyp_t_data_t* t_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv)
{
   int fx_status = 0;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM14occurs_id_kexpB2R9Ast__id_tN14K_form__kexp_t(
   struct _fx_R9Ast__id_t* i0_0,
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   bool* fx_result,
   void* fx_fv)
{
   _fx_rB id_occurs_ref_0 = 0;
   _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t occurs_atom_0 = {0};
   _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t occurs_kexp_0 = {0};
   _fx_N15K_form__kinfo_t v_0 = {0};
   _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t occurs_ktyp_0 = {0};
   _fx_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t v_1 = 0;
   _fx_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t v_2 = 0;
   _fx_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t v_3 = 0;
   _fx_R22K_form__k_fold_callb_t occurs_callb_0 = {0};
   int fx_status = 0;
   FX_CALL(_fx_make_rB(false, &id_occurs_ref_0), _fx_cleanup);
   bool* id_occurs_0 = &id_occurs_ref_0->data;
   _fx_M10C_gen_codeFM7make_fpFPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t2R9Ast__id_trB(i0_0, id_occurs_ref_0,
      &occurs_atom_0);
   _fx_M10C_gen_codeFM7make_fpFPv2N14K_form__kexp_tR22K_form__k_fold_callb_t1rB(id_occurs_ref_0, &occurs_kexp_0);
   _fx_R10Ast__loc_t loc_0;
   FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(e_0, &loc_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(i0_0, &loc_0, &v_0, 0), _fx_cleanup);
   bool f_0;
   if (v_0.tag == 2) {
      f_0 = v_0.u.KVal.kv_flags.val_flag_tempref;
   }
   else {
      f_0 = false;
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (f_0) {
      *fx_result = true;
   }
   else {
      _fx_FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t occurs_ktyp_fp_0 =
         { _fx_M10C_gen_codeFM11occurs_ktypv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t, 0 };
      FX_COPY_FP(&occurs_ktyp_fp_0, &occurs_ktyp_0);
      FX_CALL(
         _fx_M10C_gen_codeFM4SomeNt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(
            &occurs_ktyp_0, &v_1), _fx_cleanup);
      FX_CALL(
         _fx_M10C_gen_codeFM4SomeNt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
            &occurs_kexp_0, &v_2), _fx_cleanup);
      FX_CALL(
         _fx_M10C_gen_codeFM4SomeNt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
            &occurs_atom_0, &v_3), _fx_cleanup);
      _fx_make_R22K_form__k_fold_callb_t(v_1, v_2, v_3, &occurs_callb_0);
      if (!*id_occurs_0) {
         FX_CALL(_fx_M6K_formFM9fold_kexpv2N14K_form__kexp_tRM14k_fold_callb_t(e_0, &occurs_callb_0, 0), _fx_cleanup);
      }
      *fx_result = *id_occurs_0;
   }

_fx_cleanup: ;
   FX_FREE_REF_SIMPLE(&id_occurs_ref_0);
   FX_FREE_FP(&occurs_atom_0);
   FX_FREE_FP(&occurs_kexp_0);
   _fx_free_N15K_form__kinfo_t(&v_0);
   FX_FREE_FP(&occurs_ktyp_0);
   if (v_1) {
      _fx_free_Nt6option1FPv3N14K_form__ktyp_tR10Ast__loc_tR22K_form__k_fold_callb_t(&v_1);
   }
   if (v_2) {
      _fx_free_Nt6option1FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t(&v_2);
   }
   if (v_3) {
      _fx_free_Nt6option1FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(&v_3);
   }
   _fx_free_R22K_form__k_fold_callb_t(&occurs_callb_0);
   return fx_status;
}

static int _fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv)
{
   int fx_status = 0;
   _fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t* cv_0 =
      (_fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t*)fx_fv;
   if (a_0->tag == 1) {
      bool res_0;
      FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&a_0->u.AtomId, &cv_0->t0, &res_0, 0), _fx_catch_0);
      if (res_0) {
         cv_0->t1->data = true;
      }

   _fx_catch_0: ;
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM7make_fpFPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t2R9Ast__id_trB(
   struct _fx_R9Ast__id_t* arg0,
   struct _fx_rB_data_t* arg1,
   struct _fx_FPv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t* fx_result)
{
   FX_MAKE_FP_IMPL_START(_fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t_cldata_t,
      _fx_free_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t,
      _fx_M10C_gen_codeFM11occurs_atomv3N14K_form__atom_tR10Ast__loc_tR22K_form__k_fold_callb_t);
   fcv->t0 = *arg0;
   FX_COPY_PTR(arg1, &fcv->t1);
   return 0;
}

static int _fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t(
   struct _fx_N14K_form__kexp_t_data_t* e_0,
   struct _fx_R22K_form__k_fold_callb_t* callb_0,
   void* fx_fv)
{
   int fx_status = 0;
   _fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t* cv_0 =
      (_fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t*)fx_fv;
   if (!cv_0->t0->data) {
      FX_CALL(_fx_M6K_formFM9fold_kexpv2N14K_form__kexp_tRM14k_fold_callb_t(e_0, callb_0, 0), _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM7make_fpFPv2N14K_form__kexp_tR22K_form__k_fold_callb_t1rB(
   struct _fx_rB_data_t* arg0,
   struct _fx_FPv2N14K_form__kexp_tR22K_form__k_fold_callb_t* fx_result)
{
   FX_MAKE_FP_IMPL_START(_fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t_cldata_t,
      _fx_free_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t,
      _fx_M10C_gen_codeFM11occurs_kexpv2N14K_form__kexp_tR22K_form__k_fold_callb_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   return 0;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM18gen_ccode_prologueLN15C_form__cstmt_t2BR10Ast__loc_t(
   bool __0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_N14C_form__cexp_t v_0 = 0;
   _fx_N15C_form__cstmt_t v_1 = 0;
   int fx_status = 0;
   fx_str_t slit_0 =
      FX_MAKE_STR("// this is autogenerated file, do not edit it.\n"
         U"#include \"ficus/ficus.h\"\n");
   FX_CALL(_fx_M6C_formFM9CExpCCodeN14C_form__cexp_t2SR10Ast__loc_t(&slit_0, loc_0, &v_0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_0, &v_1), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1, 0, true, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (v_0) {
      _fx_free_N14C_form__cexp_t(&v_0);
   }
   if (v_1) {
      _fx_free_N15C_form__cstmt_t(&v_1);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM8gen_mainLN15C_form__cstmt_t3BLSR10Ast__loc_t(
   bool ismain_0,
   struct _fx_LS_data_t* mod_names_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_Ta3LS __fold_result___0 = {0};
   _fx_Ta3LS v_0 = {0};
   _fx_LS fwd_decls_0 = 0;
   _fx_LS init_calls_0 = 0;
   _fx_LS deinit_calls_0 = 0;
   fx_str_t v_1 = {0};
   fx_str_t v_2 = {0};
   _fx_LS __fold_result___1 = 0;
   _fx_LS v_3 = 0;
   fx_str_t v_4 = {0};
   fx_str_t v_5 = {0};
   _fx_N14C_form__cexp_t v_6 = 0;
   _fx_N15C_form__cstmt_t v_7 = 0;
   int fx_status = 0;
   if (ismain_0) {
      _fx_make_Ta3LS(0, 0, 0, &__fold_result___0);
      int_ idx_0 = 0;
      _fx_LS lst_0 = mod_names_0;
      for (; lst_0; lst_0 = lst_0->tl, idx_0 += 1) {
         _fx_Ta3LS v_8 = {0};
         _fx_LS fwd_decls_1 = 0;
         _fx_LS init_calls_1 = 0;
         _fx_LS deinit_calls_1 = 0;
         _fx_LS v_9 = 0;
         fx_str_t v_10 = {0};
         fx_str_t v_11 = {0};
         fx_str_t v_12 = {0};
         _fx_Ta3LS v_13 = {0};
         fx_str_t* m_0 = &lst_0->hd;
         _fx_copy_Ta3LS(&__fold_result___0, &v_8);
         FX_COPY_PTR(v_8.t0, &fwd_decls_1);
         FX_COPY_PTR(v_8.t1, &init_calls_1);
         FX_COPY_PTR(v_8.t2, &deinit_calls_1);
         if (idx_0 == 0) {
            FX_COPY_PTR(fwd_decls_1, &v_9);
         }
         else {
            fx_str_t slit_0 = FX_MAKE_STR("FX_EXTERN_C int fx_init_");
            fx_str_t slit_1 =
               FX_MAKE_STR("();\n"
                  U"FX_EXTERN_C void fx_deinit_");
            fx_str_t slit_2 = FX_MAKE_STR("();\n");
            {
               const fx_str_t strs_0[] = { slit_0, *m_0, slit_1, *m_0, slit_2 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_0, 5, &v_10), _fx_catch_0);
            }
            FX_CALL(_fx_cons_LS(&v_10, fwd_decls_1, true, &v_9), _fx_catch_0);
         }
         fx_str_t slit_3 = FX_MAKE_STR("  if (fx_status >= 0) fx_status = fx_init_");
         fx_str_t slit_4 = FX_MAKE_STR("();\n");
         {
            const fx_str_t strs_1[] = { slit_3, *m_0, slit_4 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_1, 3, &v_11), _fx_catch_0);
         }
         FX_CALL(_fx_cons_LS(&v_11, init_calls_1, false, &init_calls_1), _fx_catch_0);
         fx_str_t slit_5 = FX_MAKE_STR("  fx_deinit_");
         fx_str_t slit_6 = FX_MAKE_STR("();\n");
         {
            const fx_str_t strs_2[] = { slit_5, *m_0, slit_6 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_2, 3, &v_12), _fx_catch_0);
         }
         FX_CALL(_fx_cons_LS(&v_12, deinit_calls_1, false, &deinit_calls_1), _fx_catch_0);
         _fx_make_Ta3LS(v_9, init_calls_1, deinit_calls_1, &v_13);
         _fx_free_Ta3LS(&__fold_result___0);
         _fx_copy_Ta3LS(&v_13, &__fold_result___0);

      _fx_catch_0: ;
         _fx_free_Ta3LS(&v_13);
         FX_FREE_STR(&v_12);
         FX_FREE_STR(&v_11);
         FX_FREE_STR(&v_10);
         if (v_9) {
            _fx_free_LS(&v_9);
         }
         if (deinit_calls_1) {
            _fx_free_LS(&deinit_calls_1);
         }
         if (init_calls_1) {
            _fx_free_LS(&init_calls_1);
         }
         if (fwd_decls_1) {
            _fx_free_LS(&fwd_decls_1);
         }
         _fx_free_Ta3LS(&v_8);
         FX_CHECK_EXN(_fx_cleanup);
      }
      _fx_copy_Ta3LS(&__fold_result___0, &v_0);
      FX_COPY_PTR(v_0.t0, &fwd_decls_0);
      FX_COPY_PTR(v_0.t1, &init_calls_0);
      FX_COPY_PTR(v_0.t2, &deinit_calls_0);
      fx_str_t slit_7 = FX_MAKE_STR("");
      FX_CALL(_fx_F4joinS2SLS(&slit_7, fwd_decls_0, &v_1, 0), _fx_cleanup);
      fx_str_t slit_8 = FX_MAKE_STR("");
      FX_CALL(_fx_F4joinS2SLS(&slit_8, init_calls_0, &v_2, 0), _fx_cleanup);
      _fx_LS lst_1 = deinit_calls_0;
      for (; lst_1; lst_1 = lst_1->tl) {
         _fx_LS r_0 = 0;
         fx_str_t* a_0 = &lst_1->hd;
         FX_COPY_PTR(__fold_result___1, &r_0);
         FX_CALL(_fx_cons_LS(a_0, r_0, false, &r_0), _fx_catch_1);
         _fx_free_LS(&__fold_result___1);
         FX_COPY_PTR(r_0, &__fold_result___1);

      _fx_catch_1: ;
         if (r_0) {
            _fx_free_LS(&r_0);
         }
         FX_CHECK_EXN(_fx_cleanup);
      }
      FX_COPY_PTR(__fold_result___1, &v_3);
      fx_str_t slit_9 = FX_MAKE_STR("");
      FX_CALL(_fx_F4joinS2SLS(&slit_9, v_3, &v_4, 0), _fx_cleanup);
      fx_str_t slit_10 =
         FX_MAKE_STR("\n"
            U"int main(int argc, char** argv)\n"
            U"{\n"
            U"   fx_init(argc, argv);\n"
            U"   int fx_status = FX_OK;\n");
      fx_str_t slit_11 = FX_MAKE_STR("  if (fx_status < 0) fx_status = fx_print_bt();\n");
      fx_str_t slit_12 =
         FX_MAKE_STR("  return fx_deinit(fx_status);\n"
            U"}");
      {
         const fx_str_t strs_3[] = { v_1, slit_10, v_2, slit_11, v_4, slit_12 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_3, 6, &v_5), _fx_cleanup);
      }
      FX_CALL(_fx_M6C_formFM9CExpCCodeN14C_form__cexp_t2SR10Ast__loc_t(&v_5, loc_0, &v_6), _fx_cleanup);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_6, &v_7), _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_7, 0, true, fx_result), _fx_cleanup);
   }

_fx_cleanup: ;
   _fx_free_Ta3LS(&__fold_result___0);
   _fx_free_Ta3LS(&v_0);
   if (fwd_decls_0) {
      _fx_free_LS(&fwd_decls_0);
   }
   if (init_calls_0) {
      _fx_free_LS(&init_calls_0);
   }
   if (deinit_calls_0) {
      _fx_free_LS(&deinit_calls_0);
   }
   FX_FREE_STR(&v_1);
   FX_FREE_STR(&v_2);
   if (__fold_result___1) {
      _fx_free_LS(&__fold_result___1);
   }
   if (v_3) {
      _fx_free_LS(&v_3);
   }
   FX_FREE_STR(&v_4);
   FX_FREE_STR(&v_5);
   if (v_6) {
      _fx_free_N14C_form__cexp_t(&v_6);
   }
   if (v_7) {
      _fx_free_N15C_form__cstmt_t(&v_7);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM10get_structT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* cexp_0,
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* fx_result,
   void* fx_fv)
{
   _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_0 = {0};
   _fx_N14C_form__ctyp_t ctyp_0 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM12get_cexp_ctxT2N14C_form__ctyp_tR10Ast__loc_t1N14C_form__cexp_t(cexp_0, &v_0, 0), _fx_cleanup);
   FX_COPY_PTR(v_0.t0, &ctyp_0);
   _fx_R10Ast__loc_t cloc_0 = v_0.t1;
   FX_CALL(
      _fx_M10C_gen_codeFM9try_derefT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         cexp_0, ctyp_0, &cloc_0, fx_result, 0), _fx_cleanup);

_fx_cleanup: ;
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_0);
   if (ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&ctyp_0);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM9try_derefT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* cexp_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_R10Ast__loc_t* cloc_0,
   struct _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti* fx_result,
   void* fx_fv)
{
   _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti result_0 = {0};
   _fx_N14C_form__cexp_t cexp_1 = 0;
   _fx_N14C_form__ctyp_t ctyp_1 = 0;
   int fx_status = 0;
   FX_COPY_PTR(cexp_0, &cexp_1);
   FX_COPY_PTR(ctyp_0, &ctyp_1);
   for (;;) {
      _fx_N14C_form__cexp_t cexp_2 = 0;
      _fx_N14C_form__ctyp_t ctyp_2 = 0;
      FX_COPY_PTR(cexp_1, &cexp_2);
      FX_COPY_PTR(ctyp_1, &ctyp_2);
      if (FX_REC_VARIANT_TAG(ctyp_2) == 17) {
         _fx_N14C_form__cexp_t v_0 = 0;
         FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(cexp_2, &v_0, 0), _fx_catch_0);
         _fx_free_N14C_form__cexp_t(&cexp_1);
         FX_COPY_PTR(v_0, &cexp_1);
         _fx_N14C_form__ctyp_t* ctyp1_0 = &ctyp_2->u.CTypRawPtr.t1;
         _fx_free_N14C_form__ctyp_t(&ctyp_1);
         FX_COPY_PTR(*ctyp1_0, &ctyp_1);

      _fx_catch_0: ;
         if (v_0) {
            _fx_free_N14C_form__cexp_t(&v_0);
         }
      }
      else {
         int tag_0 = FX_REC_VARIANT_TAG(ctyp_2);
         if (tag_0 == 21) {
            _fx_N15C_form__cinfo_t v_1 = {0};
            _fx_R17C_form__cdeftyp_t v_2 = {0};
            _fx_R17C_form__cdeftyp_t v_3 = {0};
            _fx_R9Ast__id_t* tn_0 = &ctyp_2->u.CTypName;
            FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(tn_0, cloc_0, &v_1, 0), _fx_catch_4);
            int tag_1 = v_1.tag;
            if (tag_1 == 4) {
               _fx_copy_R17C_form__cdeftyp_t(&v_1.u.CTyp->data, &v_2);
               _fx_N14C_form__ctyp_t v_4 = v_2.ct_typ;
               if (FX_REC_VARIANT_TAG(v_4) == 14) {
                  _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti result_1 = {0};
                  _fx_make_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(tn_0, cexp_2, v_4->u.CTypStruct.t1,
                     v_2.ct_data_start, &result_1);
                  _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_0);
                  _fx_copy_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_1, &result_0);
                  FX_BREAK(_fx_catch_1);

               _fx_catch_1: ;
                  _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_1);
                  goto _fx_endmatch_0;
               }
            }
            if (tag_1 == 4) {
               _fx_copy_R17C_form__cdeftyp_t(&v_1.u.CTyp->data, &v_3);
               _fx_N14C_form__ctyp_t v_5 = v_3.ct_typ;
               if (FX_REC_VARIANT_TAG(v_5) == 17) {
                  _fx_N14C_form__ctyp_t v_6 = v_5->u.CTypRawPtr.t1;
                  if (FX_REC_VARIANT_TAG(v_6) == 14) {
                     _fx_N14C_form__cexp_t v_7 = 0;
                     _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti result_2 = {0};
                     _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* vcase_0 = &v_6->u.CTypStruct;
                     _fx_Nt6option1R9Ast__id_t* rn_0 = &vcase_0->t0;
                     _fx_R9Ast__id_t v_8;
                     if (rn_0->tag == 2) {
                        v_8 = rn_0->u.Some;
                     }
                     else {
                        v_8 = _fx_g9Ast__noid;
                     }
                     FX_CHECK_EXN(_fx_catch_2);
                     FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(cexp_2, &v_7, 0), _fx_catch_2);
                     _fx_make_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&v_8, v_7, vcase_0->t1,
                        v_3.ct_data_start, &result_2);
                     _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_0);
                     _fx_copy_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_2, &result_0);
                     FX_BREAK(_fx_catch_2);

                  _fx_catch_2: ;
                     _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_2);
                     if (v_7) {
                        _fx_free_N14C_form__cexp_t(&v_7);
                     }
                     goto _fx_endmatch_0;
                  }
               }
            }
            fx_str_t v_9 = {0};
            fx_str_t v_10 = {0};
            fx_exn_t v_11 = {0};
            FX_CALL(_fx_M6C_formFM13get_idc_cnameS2R9Ast__id_tR10Ast__loc_t(tn_0, cloc_0, &v_9, 0), _fx_catch_3);
            fx_str_t slit_0 = FX_MAKE_STR("the type \'");
            fx_str_t slit_1 = FX_MAKE_STR("\' is not a structure");
            {
               const fx_str_t strs_0[] = { slit_0, v_9, slit_1 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_0, 3, &v_10), _fx_catch_3);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(cloc_0, &v_10, &v_11, 0), _fx_catch_3);
            FX_THROW(&v_11, false, _fx_catch_3);

         _fx_catch_3: ;
            fx_free_exn(&v_11);
            FX_FREE_STR(&v_10);
            FX_FREE_STR(&v_9);

         _fx_endmatch_0: ;
            FX_CHECK_EXN(_fx_catch_4);

         _fx_catch_4: ;
            _fx_free_R17C_form__cdeftyp_t(&v_3);
            _fx_free_R17C_form__cdeftyp_t(&v_2);
            _fx_free_N15C_form__cinfo_t(&v_1);
         }
         else if (tag_0 == 14) {
            _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti result_3 = {0};
            _fx_T2Nt6option1R9Ast__id_tLT2R9Ast__id_tN14C_form__ctyp_t* vcase_1 = &ctyp_2->u.CTypStruct;
            _fx_Nt6option1R9Ast__id_t* rn_1 = &vcase_1->t0;
            _fx_R9Ast__id_t v_12;
            if (rn_1->tag == 2) {
               v_12 = rn_1->u.Some;
            }
            else {
               v_12 = _fx_g9Ast__noid;
            }
            FX_CHECK_EXN(_fx_catch_5);
            _fx_make_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&v_12, cexp_2, vcase_1->t1, 0, &result_3);
            _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_0);
            _fx_copy_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_3, &result_0);
            FX_BREAK(_fx_catch_5);

         _fx_catch_5: ;
            _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_3);
         }
         else {
            fx_exn_t v_13 = {0};
            fx_str_t slit_2 = FX_MAKE_STR("a structure is expected here");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(cloc_0, &slit_2, &v_13, 0), _fx_catch_6);
            FX_THROW(&v_13, false, _fx_catch_6);

         _fx_catch_6: ;
            fx_free_exn(&v_13);
         }
         FX_CHECK_EXN(_fx_catch_7);

      _fx_catch_7: ;
      }
      FX_CHECK_EXN(_fx_catch_8);

   _fx_catch_8: ;
      if (ctyp_2) {
         _fx_free_N14C_form__ctyp_t(&ctyp_2);
      }
      if (cexp_2) {
         _fx_free_N14C_form__cexp_t(&cexp_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_0, fx_result);

_fx_cleanup: ;
   _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&result_0);
   if (cexp_1) {
      _fx_free_N14C_form__cexp_t(&cexp_1);
   }
   if (ctyp_1) {
      _fx_free_N14C_form__ctyp_t(&ctyp_1);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM15unpack_fun_argsT4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tB(
   struct _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t_data_t* args_0,
   struct _fx_N14C_form__ctyp_t_data_t* rt_0,
   bool is_nothrow_0,
   struct _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB* fx_result,
   void* fx_fv)
{
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t __fold_result___0 = 0;
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t v_0 = 0;
   _fx_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB v_1 = {0};
   _fx_LN19C_form__carg_attr_t flags_0 = 0;
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t real_args_0 = 0;
   _fx_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t v_2 = {0};
   _fx_LN19C_form__carg_attr_t flags_1 = 0;
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t real_args_1 = 0;
   _fx_N14C_form__ctyp_t ret_rt_0 = 0;
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t __fold_result___1 = 0;
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t real_args_2 = 0;
   int fx_status = 0;
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t lst_0 = args_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t r_0 = 0;
      _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* a_0 = &lst_0->hd;
      FX_COPY_PTR(__fold_result___0, &r_0);
      FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(a_0, r_0, false, &r_0), _fx_catch_0);
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&__fold_result___0);
      FX_COPY_PTR(r_0, &__fold_result___0);

   _fx_catch_0: ;
      if (r_0) {
         _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, &v_0);
   if (v_0 != 0) {
      bool __fold_result___2 = false;
      FX_COPY_PTR(v_0->hd.t2, &flags_0);
      _fx_LN19C_form__carg_attr_t lst_1 = flags_0;
      for (; lst_1; lst_1 = lst_1->tl) {
         _fx_N19C_form__carg_attr_t* b_0 = &lst_1->hd;
         if (3 == b_0->tag) {
            __fold_result___2 = true; FX_BREAK(_fx_catch_1);
         }

      _fx_catch_1: ;
         FX_CHECK_BREAK();
         FX_CHECK_EXN(_fx_cleanup);
      }
      if (__fold_result___2) {
         _fx_make_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB(v_0->tl, true, &v_1); goto _fx_endmatch_0;
      }
   }
   _fx_make_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB(v_0, false, &v_1);

_fx_endmatch_0: ;
   FX_CHECK_EXN(_fx_cleanup);
   FX_COPY_PTR(v_1.t0, &real_args_0);
   bool have_fv_arg_0 = v_1.t1;
   if (real_args_0 != 0) {
      _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* v_3 = &real_args_0->hd;
      bool __fold_result___3 = false;
      FX_COPY_PTR(v_3->t2, &flags_1);
      _fx_LN19C_form__carg_attr_t lst_2 = flags_1;
      for (; lst_2; lst_2 = lst_2->tl) {
         _fx_N19C_form__carg_attr_t* b_1 = &lst_2->hd;
         if (2 == b_1->tag) {
            __fold_result___3 = true; FX_BREAK(_fx_catch_2);
         }

      _fx_catch_2: ;
         FX_CHECK_BREAK();
         FX_CHECK_EXN(_fx_cleanup);
      }
      if (__fold_result___3) {
         _fx_make_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t(real_args_0->tl,
            &v_3->t0, v_3->t1, &v_2);
         goto _fx_endmatch_1;
      }
   }
   _fx_N14C_form__ctyp_t v_4 = 0;
   if (is_nothrow_0) {
      FX_COPY_PTR(rt_0, &v_4);
   }
   else {
      FX_COPY_PTR(_fx_g20C_gen_code__CTypVoid, &v_4);
   }
   _fx_make_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t(real_args_0, &_fx_g9Ast__noid,
      v_4, &v_2);
   if (v_4) {
      _fx_free_N14C_form__ctyp_t(&v_4);
   }

_fx_endmatch_1: ;
   FX_CHECK_EXN(_fx_cleanup);
   FX_COPY_PTR(v_2.t0, &real_args_1);
   _fx_R9Ast__id_t ret_id_0 = v_2.t1;
   FX_COPY_PTR(v_2.t2, &ret_rt_0);
   _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t lst_3 = real_args_1;
   for (; lst_3; lst_3 = lst_3->tl) {
      _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t r_1 = 0;
      _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* a_1 = &lst_3->hd;
      FX_COPY_PTR(__fold_result___1, &r_1);
      FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(a_1, r_1, false, &r_1), _fx_catch_3);
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&__fold_result___1);
      FX_COPY_PTR(r_1, &__fold_result___1);

   _fx_catch_3: ;
      if (r_1) {
         _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&r_1);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___1, &real_args_2);
   _fx_make_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB(real_args_2, &ret_id_0,
      ret_rt_0, have_fv_arg_0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&__fold_result___0);
   }
   if (v_0) {
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&v_0);
   }
   _fx_free_T2LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tB(&v_1);
   FX_FREE_LIST_SIMPLE(&flags_0);
   if (real_args_0) {
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&real_args_0);
   }
   _fx_free_T3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_t(&v_2);
   FX_FREE_LIST_SIMPLE(&flags_1);
   if (real_args_1) {
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&real_args_1);
   }
   if (ret_rt_0) {
      _fx_free_N14C_form__ctyp_t(&ret_rt_0);
   }
   if (__fold_result___1) {
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&__fold_result___1);
   }
   if (real_args_2) {
      _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&real_args_2);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* cc_0,
   struct _fx_N15C_form__cstmt_t_data_t* then_s_0,
   struct _fx_N15C_form__cstmt_t_data_t* else_s_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   int tag_0 = FX_REC_VARIANT_TAG(then_s_0);
   bool res_0;
   if (tag_0 == 1) {
      res_0 = true; goto _fx_endmatch_0;
   }
   if (tag_0 == 7) {
      if (then_s_0->u.CStmtBlock.t0 == 0) {
         res_0 = true; goto _fx_endmatch_0;
      }
   }
   res_0 = false;

_fx_endmatch_0: ;
   FX_CHECK_EXN(_fx_cleanup);
   if (res_0) {
      _fx_N14C_form__cexp_t inv_cc_0 = 0;
      _fx_N15C_form__cstmt_t v_0 = 0;
      _fx_R10Ast__loc_t then_loc_0;
      FX_CALL(_fx_M6C_formFM13get_cstmt_locR10Ast__loc_t1N15C_form__cstmt_t(then_s_0, &then_loc_0, 0), _fx_catch_2);
      int tag_1 = FX_REC_VARIANT_TAG(cc_0);
      if (tag_1 == 3) {
         _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* vcase_0 =
            &cc_0->u.CExpBinary;
         _fx_N17C_form__cbinary_t* v_1 = &vcase_0->t0;
         if (v_1->tag == 13) {
            int tag_2 = v_1->u.COpCmp.tag;
            _fx_N12Ast__cmpop_t inv_cmp_0;
            if (tag_2 == 1) {
               inv_cmp_0 = _fx_g17C_gen_code__CmpNE;
            }
            else if (tag_2 == 2) {
               inv_cmp_0 = _fx_g17C_gen_code__CmpEQ;
            }
            else if (tag_2 == 3) {
               inv_cmp_0 = _fx_g17C_gen_code__CmpGE;
            }
            else if (tag_2 == 4) {
               inv_cmp_0 = _fx_g17C_gen_code__CmpGT;
            }
            else if (tag_2 == 6) {
               inv_cmp_0 = _fx_g17C_gen_code__CmpLE;
            }
            else if (tag_2 == 5) {
               inv_cmp_0 = _fx_g17C_gen_code__CmpLT;
            }
            else {
               FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_0);
            }
            FX_CHECK_EXN(_fx_catch_0);
            _fx_N17C_form__cbinary_t v_2;
            _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&inv_cmp_0, &v_2);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &v_2, vcase_0->t1, vcase_0->t2, &vcase_0->t3, &inv_cc_0), _fx_catch_0);

         _fx_catch_0: ;
            goto _fx_endmatch_1;
         }
      }
      if (tag_1 == 4) {
         _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* vcase_1 = &cc_0->u.CExpUnary;
         if (vcase_1->t0.tag == 4) {
            FX_COPY_PTR(vcase_1->t1, &inv_cc_0); goto _fx_endmatch_1;
         }
      }
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t cc_ctx_0 = {0};
      FX_CALL(_fx_M6C_formFM12get_cexp_ctxT2N14C_form__ctyp_tR10Ast__loc_t1N14C_form__cexp_t(cc_0, &cc_ctx_0, 0), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g23C_gen_code__COpLogicNot, cc_0, &cc_ctx_0, &inv_cc_0), _fx_catch_1);

   _fx_catch_1: ;
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&cc_ctx_0);

   _fx_endmatch_1: ;
      FX_CHECK_EXN(_fx_catch_2);
      FX_CALL(_fx_M6C_formFM8CStmtNopN15C_form__cstmt_t1R10Ast__loc_t(&then_loc_0, &v_0), _fx_catch_2);
      FX_CALL(
         _fx_M6C_formFM7CStmtIfN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(inv_cc_0,
            else_s_0, v_0, loc_0, fx_result), _fx_catch_2);

   _fx_catch_2: ;
      if (v_0) {
         _fx_free_N15C_form__cstmt_t(&v_0);
      }
      if (inv_cc_0) {
         _fx_free_N14C_form__cexp_t(&inv_cc_0);
      }
      goto _fx_endmatch_2;
   }
   FX_CALL(
      _fx_M6C_formFM7CStmtIfN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(cc_0,
         then_s_0, else_s_0, loc_0, fx_result), _fx_catch_3);

_fx_catch_3: ;

_fx_endmatch_2: ;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM24is_immutable_atomic_cexpB1N14C_form__cexp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   int tag_0 = FX_REC_VARIANT_TAG(e_0);
   if (tag_0 == 2) {
      *fx_result = true;
   }
   else if (tag_0 == 1) {
      _fx_R17C_form__ctprops_t v_0 = {0};
      _fx_N15C_form__cinfo_t v_1 = {0};
      _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* vcase_0 = &e_0->u.CExpIdent;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t* v_2 = &vcase_0->t1;
      _fx_R10Ast__loc_t* loc_0 = &v_2->t1;
      FX_CALL(_fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(v_2->t0, loc_0, &v_0, 0),
         _fx_catch_0);
      bool ctp_scalar_0 = v_0.ctp_scalar;
      if (ctp_scalar_0) {
         FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(&vcase_0->t0, loc_0, &v_1, 0), _fx_catch_0);
         if (v_1.tag == 2) {
            *fx_result = !v_1.u.CVal.cv_flags.val_flag_mutable;
         }
         else {
            *fx_result = false;
         }
         FX_CHECK_EXN(_fx_catch_0);
      }
      else {
         *fx_result = false;
      }

   _fx_catch_0: ;
      _fx_free_N15C_form__cinfo_t(&v_1);
      _fx_free_R17C_form__ctprops_t(&v_0);
   }
   else {
      *fx_result = false;
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM7fix_nilN14C_form__cexp_t2N14C_form__cexp_tN14K_form__ktyp_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_N14K_form__ktyp_t_data_t* ktyp_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (FX_REC_VARIANT_TAG(e_0) == 10) {
      if (e_0->u.CExpInit.t0 == 0) {
         _fx_R10Ast__loc_t loc_0;
         FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(e_0, &loc_0, 0), _fx_catch_0);
         _fx_R17K_form__ktprops_t v_0;
         FX_CALL(_fx_M10K_annotateFM11get_ktpropsR17K_form__ktprops_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_0, &loc_0, &v_0, 0),
            _fx_catch_0);
         bool ktp_ptr_0 = v_0.ktp_ptr;
         bool ktp_scalar_0 = v_0.ktp_scalar;
         bool t_0;
         if (ktp_scalar_0) {
            t_0 = true;
         }
         else {
            t_0 = ktp_ptr_0;
         }
         if (!t_0) {
            FX_COPY_PTR(e_0, fx_result);
         }
         else {
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &loc_0, fx_result, 0), _fx_catch_0);
         }

      _fx_catch_0: ;
         goto _fx_endmatch_0;
      }
   }
   FX_COPY_PTR(e_0, fx_result);

_fx_endmatch_0: ;
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_R9Ast__id_t* arr_id_0,
   struct _fx_N14C_form__ctyp_t_data_t* elem_ctyp_0,
   struct _fx_LN14C_form__cexp_t_data_t* arr_data_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (arr_data_0 == 0) {
      _fx_N14C_form__cexp_t v_0 = 0;
      FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_0, 0), _fx_catch_0);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_0, ccode_0, fx_result);

   _fx_catch_0: ;
      if (v_0) {
         _fx_free_N14C_form__cexp_t(&v_0);
      }
   }
   else {
      _fx_LN19C_form__ctyp_attr_t v_1 = 0;
      _fx_N14C_form__ctyp_t arr_ctyp_0 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_2 = {0};
      _fx_N14C_form__cexp_t arr_data_exp_0 = 0;
      _fx_R16Ast__val_flags_t v_3 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_4 = {0};
      FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_1), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_1, elem_ctyp_0, &arr_ctyp_0),
         _fx_catch_1);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(arr_ctyp_0, loc_0, &v_2);
      FX_CALL(
         _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(arr_data_0, &v_2,
            &arr_data_exp_0), _fx_catch_1);
      FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_3, 0), _fx_catch_1);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(arr_data_exp_0, &v_4);
      fx_str_t slit_0 = FX_MAKE_STR("");
      FX_CALL(
         _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
            arr_id_0, arr_ctyp_0, &v_3, &slit_0, &v_4, ccode_0, loc_0, fx_result, 0), _fx_catch_1);

   _fx_catch_1: ;
      _fx_free_Nt6option1N14C_form__cexp_t(&v_4);
      _fx_free_R16Ast__val_flags_t(&v_3);
      if (arr_data_exp_0) {
         _fx_free_N14C_form__cexp_t(&arr_data_exp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_2);
      if (arr_ctyp_0) {
         _fx_free_N14C_form__ctyp_t(&arr_ctyp_0);
      }
      FX_FREE_LIST_SIMPLE(&v_1);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(
   struct _fx_N14C_form__ctyp_t_data_t* elem_ctyp_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_Ta3N14C_form__cexp_t* fx_result,
   void* fx_fv)
{
   _fx_N14C_form__cexp_t v_0 = 0;
   _fx_LN14C_form__cexp_t v_1 = 0;
   _fx_N14C_form__cexp_t sizeof_elem_exp_0 = 0;
   _fx_T2BNt6option1N14C_form__cexp_t v_2 = {0};
   _fx_N14C_form__cexp_t free_f_exp_0 = 0;
   _fx_T2BNt6option1N14C_form__cexp_t v_3 = {0};
   _fx_N14C_form__cexp_t copy_f_exp_0 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_0, loc_0, &v_0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_0, 0, true, &v_1), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g18C_form__std_sizeof, v_1, _fx_g22C_gen_code__CTypSize_t, loc_0, &sizeof_elem_exp_0, 0), _fx_cleanup);
   FX_CALL(
      _fx_M11C_gen_typesFM10get_free_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(elem_ctyp_0, true, false,
         loc_0, &v_2, 0), _fx_cleanup);
   _fx_Nt6option1N14C_form__cexp_t* v_4 = &v_2.t1;
   if (v_4->tag == 2) {
      FX_CALL(
         _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_4->u.Some,
            _fx_g21C_form__std_fx_free_t, loc_0, &free_f_exp_0), _fx_catch_0);

   _fx_catch_0: ;
   }
   else {
      FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &free_f_exp_0, 0), _fx_catch_1);

   _fx_catch_1: ;
   }
   FX_CHECK_EXN(_fx_cleanup);
   FX_CALL(
      _fx_M11C_gen_typesFM10get_copy_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(elem_ctyp_0, true, false,
         loc_0, &v_3, 0), _fx_cleanup);
   _fx_Nt6option1N14C_form__cexp_t* v_5 = &v_3.t1;
   if (v_5->tag == 2) {
      FX_CALL(
         _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_5->u.Some,
            _fx_g21C_form__std_fx_copy_t, loc_0, &copy_f_exp_0), _fx_catch_2);

   _fx_catch_2: ;
   }
   else {
      FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &copy_f_exp_0, 0), _fx_catch_3);

   _fx_catch_3: ;
   }
   FX_CHECK_EXN(_fx_cleanup);
   _fx_make_Ta3N14C_form__cexp_t(sizeof_elem_exp_0, free_f_exp_0, copy_f_exp_0, fx_result);

_fx_cleanup: ;
   if (v_0) {
      _fx_free_N14C_form__cexp_t(&v_0);
   }
   if (v_1) {
      _fx_free_LN14C_form__cexp_t(&v_1);
   }
   if (sizeof_elem_exp_0) {
      _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_0);
   }
   _fx_free_T2BNt6option1N14C_form__cexp_t(&v_2);
   if (free_f_exp_0) {
      _fx_free_N14C_form__cexp_t(&free_f_exp_0);
   }
   _fx_free_T2BNt6option1N14C_form__cexp_t(&v_3);
   if (copy_f_exp_0) {
      _fx_free_N14C_form__cexp_t(&copy_f_exp_0);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(
   struct _fx_N14C_form__cexp_t_data_t* e_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t ctyp_0 = 0;
   _fx_R17C_form__ctprops_t v_0 = {0};
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(e_0, &ctyp_0, 0), _fx_cleanup);
   FX_CALL(_fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, loc_0, &v_0, 0),
      _fx_cleanup);
   bool ctp_pass_by_ref_0 = v_0.ctp_pass_by_ref;
   if (ctp_pass_by_ref_0) {
      FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_0, fx_result, 0), _fx_cleanup);
   }
   else {
      FX_COPY_PTR(e_0, fx_result);
   }

_fx_cleanup: ;
   if (ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&ctyp_0);
   }
   _fx_free_R17C_form__ctprops_t(&v_0);
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM19maybe_deref_fun_argT2N14C_form__cexp_tN14C_form__ctyp_t5iN14C_form__cexp_tN14C_form__ctyp_tLN19C_form__carg_attr_tR10Ast__loc_t(
   int_ idx_0,
   struct _fx_N14C_form__cexp_t_data_t* arg_0,
   struct _fx_N14C_form__ctyp_t_data_t* t_0,
   struct _fx_LN19C_form__carg_attr_t_data_t* flags_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2N14C_form__cexp_tN14C_form__ctyp_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   bool __fold_result___0 = false;
   _fx_LN19C_form__carg_attr_t lst_0 = flags_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_N19C_form__carg_attr_t* b_0 = &lst_0->hd;
      if (1 == b_0->tag) {
         __fold_result___0 = true; FX_BREAK(_fx_catch_0);
      }

   _fx_catch_0: ;
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   bool v_0 = __fold_result___0;
   if (v_0 == true) {
      if (FX_REC_VARIANT_TAG(t_0) == 17) {
         _fx_N14C_form__cexp_t v_1 = 0;
         FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(arg_0, &v_1, 0), _fx_catch_1);
         _fx_make_T2N14C_form__cexp_tN14C_form__ctyp_t(v_1, t_0->u.CTypRawPtr.t1, fx_result);

      _fx_catch_1: ;
         if (v_1) {
            _fx_free_N14C_form__cexp_t(&v_1);
         }
         goto _fx_endmatch_0;
      }
   }
   if (v_0 == true) {
      fx_str_t v_2 = {0};
      fx_str_t v_3 = {0};
      fx_exn_t v_4 = {0};
      FX_CALL(_fx_F6stringS1i(idx_0, &v_2, 0), _fx_catch_2);
      fx_str_t slit_0 = FX_MAKE_STR("cgen: invalid type of argument #");
      fx_str_t slit_1 = FX_MAKE_STR("; it\'s passed by pointer, but the type is not pointer");
      {
         const fx_str_t strs_0[] = { slit_0, v_2, slit_1 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_0, 3, &v_3), _fx_catch_2);
      }
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_3, &v_4, 0), _fx_catch_2);
      FX_THROW(&v_4, false, _fx_catch_2);

   _fx_catch_2: ;
      fx_free_exn(&v_4);
      FX_FREE_STR(&v_3);
      FX_FREE_STR(&v_2);
      goto _fx_endmatch_0;
   }
   _fx_make_T2N14C_form__cexp_tN14C_form__ctyp_t(arg_0, t_0, fx_result);

_fx_endmatch_0: ;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM17add_size_eq_checkLN15C_form__cstmt_t4LN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
   struct _fx_LN14C_form__cexp_t_data_t* check_list_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_N14C_form__cexp_t_data_t* lbl_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (check_list_0 != 0) {
      _fx_N14C_form__cexp_t __fold_result___0 = 0;
      _fx_LN14C_form__cexp_t rest_0 = 0;
      _fx_N14C_form__cexp_t check_exp_0 = 0;
      _fx_LN14C_form__cexp_t v_0 = 0;
      _fx_N14C_form__cexp_t check_call_0 = 0;
      _fx_N15C_form__cstmt_t v_1 = 0;
      FX_COPY_PTR(check_list_0->hd, &__fold_result___0);
      FX_COPY_PTR(check_list_0->tl, &rest_0);
      _fx_LN14C_form__cexp_t lst_0 = rest_0;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_N14C_form__cexp_t check_exp_1 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_2 = {0};
         _fx_N14C_form__cexp_t v_3 = 0;
         _fx_N14C_form__cexp_t check_i_0 = lst_0->hd;
         FX_COPY_PTR(__fold_result___0, &check_exp_1);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, loc_0, &v_2);
         FX_CALL(
            _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g23C_gen_code__COpLogicAnd, check_exp_1, check_i_0, &v_2, &v_3), _fx_catch_0);
         _fx_free_N14C_form__cexp_t(&__fold_result___0);
         FX_COPY_PTR(v_3, &__fold_result___0);

      _fx_catch_0: ;
         if (v_3) {
            _fx_free_N14C_form__cexp_t(&v_3);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_2);
         if (check_exp_1) {
            _fx_free_N14C_form__cexp_t(&check_exp_1);
         }
         FX_CHECK_EXN(_fx_catch_1);
      }
      FX_COPY_PTR(__fold_result___0, &check_exp_0);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_0, 0, true, &v_0), _fx_catch_1);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(check_exp_0, v_0, false, &v_0), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g28C_form__std_FX_CHECK_EQ_SIZE, v_0, _fx_g20C_gen_code__CTypVoid, loc_0, &check_call_0, 0), _fx_catch_1);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(check_call_0, &v_1), _fx_catch_1);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1, ccode_0, true, fx_result), _fx_catch_1);

   _fx_catch_1: ;
      if (v_1) {
         _fx_free_N15C_form__cstmt_t(&v_1);
      }
      if (check_call_0) {
         _fx_free_N14C_form__cexp_t(&check_call_0);
      }
      if (v_0) {
         _fx_free_LN14C_form__cexp_t(&v_0);
      }
      if (check_exp_0) {
         _fx_free_N14C_form__cexp_t(&check_exp_0);
      }
      if (rest_0) {
         _fx_free_LN14C_form__cexp_t(&rest_0);
      }
      if (__fold_result___0) {
         _fx_free_N14C_form__cexp_t(&__fold_result___0);
      }
   }
   else {
      FX_COPY_PTR(ccode_0, fx_result);
   }
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM11for_err_msgS4iiiS(
   int_ for_idx_0,
   int_ nfors_0,
   int_ i_0,
   fx_str_t* msg_0,
   fx_str_t* fx_result,
   void* fx_fv)
{
   fx_str_t for_msg_prefix_0 = {0};
   fx_str_t v_0 = {0};
   fx_str_t v_1 = {0};
   fx_str_t it_clause_0 = {0};
   fx_str_t v_2 = {0};
   fx_str_t v_3 = {0};
   int fx_status = 0;
   if (nfors_0 == 1) {
      fx_str_t slit_0 = FX_MAKE_STR(""); fx_copy_str(&slit_0, &for_msg_prefix_0);
   }
   else if (for_idx_0 == 0) {
      fx_str_t slit_1 = FX_MAKE_STR("the outermost "); fx_copy_str(&slit_1, &for_msg_prefix_0);
   }
   else if (for_idx_0 == nfors_0 - 1) {
      fx_str_t slit_2 = FX_MAKE_STR("the innermost "); fx_copy_str(&slit_2, &for_msg_prefix_0);
   }
   else {
      FX_CALL(_fx_F6stringS1i(for_idx_0, &v_0, 0), _fx_cleanup);
      FX_CALL(_fx_M6StringFM10num_suffixS1i(for_idx_0, &v_1, 0), _fx_cleanup);
      fx_str_t slit_3 = FX_MAKE_STR("-");
      fx_str_t slit_4 = FX_MAKE_STR(" nested ");
      {
         const fx_str_t strs_0[] = { v_0, slit_3, v_1, slit_4 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_0, 4, &for_msg_prefix_0), _fx_cleanup);
      }
   }
   int_ i_1 = i_0 + 1;
   if (i_1 <= 0) {
      fx_str_t slit_5 = FX_MAKE_STR(""); fx_copy_str(&slit_5, &it_clause_0);
   }
   else {
      FX_CALL(_fx_F6stringS1i(i_1, &v_2, 0), _fx_cleanup);
      FX_CALL(_fx_M6StringFM10num_suffixS1i(i_1, &v_3, 0), _fx_cleanup);
      fx_str_t slit_6 = FX_MAKE_STR(", ");
      fx_str_t slit_7 = FX_MAKE_STR("-");
      fx_str_t slit_8 = FX_MAKE_STR(" iteration clause");
      {
         const fx_str_t strs_1[] = { slit_6, v_2, slit_7, v_3, slit_8 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_1, 5, &it_clause_0), _fx_cleanup);
      }
   }
   fx_str_t slit_9 = FX_MAKE_STR("cgen: ");
   fx_str_t slit_10 = FX_MAKE_STR("for-loop");
   fx_str_t slit_11 = FX_MAKE_STR(": ");
   {
      const fx_str_t strs_2[] = { slit_9, for_msg_prefix_0, slit_10, it_clause_0, slit_11, *msg_0 };
      FX_CALL(fx_strjoin(0, 0, 0, strs_2, 6, fx_result), _fx_cleanup);
   }

_fx_cleanup: ;
   FX_FREE_STR(&for_msg_prefix_0);
   FX_FREE_STR(&v_0);
   FX_FREE_STR(&v_1);
   FX_FREE_STR(&it_clause_0);
   FX_FREE_STR(&v_2);
   FX_FREE_STR(&v_3);
   return fx_status;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM17compute_for_ndimsi4iiLT2R9Ast__id_tN13K_form__dom_tR10Ast__loc_t(
   int_ for_idx_0,
   int_ nfors_0,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* idoml_0,
   struct _fx_R10Ast__loc_t* for_loc_0,
   int_* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   int_ __fold_result___0 = 0;
   int_ i_0 = nfors_0 + 1;
   int_ k_0 = 0;
   _fx_LT2R9Ast__id_tN13K_form__dom_t lst_0 = idoml_0;
   for (; lst_0; lst_0 = lst_0->tl, k_0 += 1) {
      _fx_N13K_form__dom_t dom_i_0 = {0};
      fx_str_t v_0 = {0};
      fx_str_t v_1 = {0};
      fx_str_t for_msg_prefix_0 = {0};
      fx_str_t v_2 = {0};
      fx_str_t v_3 = {0};
      fx_str_t it_clause_0 = {0};
      fx_str_t v_4 = {0};
      fx_str_t v_5 = {0};
      fx_str_t v_6 = {0};
      fx_exn_t v_7 = {0};
      _fx_T2R9Ast__id_tN13K_form__dom_t* __pat___0 = &lst_0->hd;
      _fx_copy_N13K_form__dom_t(&__pat___0->t1, &dom_i_0);
      int_ ndims_0 = __fold_result___0;
      int_ ndims_i_0;
      if (dom_i_0.tag == 1) {
         _fx_N14K_form__atom_t* v_8 = &dom_i_0.u.DomainElem;
         if (v_8->tag == 1) {
            _fx_N14K_form__ktyp_t v_9 = 0;
            FX_CALL(_fx_M6K_formFM12get_idk_ktypN14K_form__ktyp_t2R9Ast__id_tR10Ast__loc_t(&v_8->u.AtomId, for_loc_0, &v_9, 0),
               _fx_catch_0);
            if (FX_REC_VARIANT_TAG(v_9) == 17) {
               ndims_i_0 = v_9->u.KTypArray.t0;
            }
            else {
               ndims_i_0 = 1;
            }
            FX_CHECK_EXN(_fx_catch_0);

         _fx_catch_0: ;
            if (v_9) {
               _fx_free_N14K_form__ktyp_t(&v_9);
            }
            goto _fx_endmatch_0;
         }
      }
      ndims_i_0 = 1;

   _fx_endmatch_0: ;
      FX_CHECK_EXN(_fx_catch_1);
      bool t_0;
      if (ndims_0 != 0) {
         t_0 = ndims_0 != ndims_i_0;
      }
      else {
         t_0 = false;
      }
      if (t_0) {
         FX_CALL(_fx_F6stringS1i(ndims_0, &v_0, 0), _fx_catch_1);
         FX_CALL(_fx_F6stringS1i(ndims_i_0, &v_1, 0), _fx_catch_1);
         if (for_idx_0 == 1) {
            fx_str_t slit_0 = FX_MAKE_STR(""); fx_copy_str(&slit_0, &for_msg_prefix_0);
         }
         else if (k_0 == 0) {
            fx_str_t slit_1 = FX_MAKE_STR("the outermost "); fx_copy_str(&slit_1, &for_msg_prefix_0);
         }
         else if (k_0 == for_idx_0 - 1) {
            fx_str_t slit_2 = FX_MAKE_STR("the innermost "); fx_copy_str(&slit_2, &for_msg_prefix_0);
         }
         else {
            FX_CALL(_fx_F6stringS1i(k_0, &v_2, 0), _fx_catch_1);
            FX_CALL(_fx_M6StringFM10num_suffixS1i(k_0, &v_3, 0), _fx_catch_1);
            fx_str_t slit_3 = FX_MAKE_STR("-");
            fx_str_t slit_4 = FX_MAKE_STR(" nested ");
            {
               const fx_str_t strs_0[] = { v_2, slit_3, v_3, slit_4 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_0, 4, &for_msg_prefix_0), _fx_catch_1);
            }
         }
         if (i_0 <= 0) {
            fx_str_t slit_5 = FX_MAKE_STR(""); fx_copy_str(&slit_5, &it_clause_0);
         }
         else {
            FX_CALL(_fx_F6stringS1i(i_0, &v_4, 0), _fx_catch_1);
            FX_CALL(_fx_M6StringFM10num_suffixS1i(i_0, &v_5, 0), _fx_catch_1);
            fx_str_t slit_6 = FX_MAKE_STR(", ");
            fx_str_t slit_7 = FX_MAKE_STR("-");
            fx_str_t slit_8 = FX_MAKE_STR(" iteration clause");
            {
               const fx_str_t strs_1[] = { slit_6, v_4, slit_7, v_5, slit_8 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_1, 5, &it_clause_0), _fx_catch_1);
            }
         }
         fx_str_t slit_9 = FX_MAKE_STR("cgen: ");
         fx_str_t slit_10 = FX_MAKE_STR("for-loop");
         fx_str_t slit_11 =
            FX_MAKE_STR(": dimensionalities of the simultaneously iterated collections/ranges are not the same (...");
         fx_str_t slit_12 = FX_MAKE_STR("...");
         fx_str_t slit_13 = FX_MAKE_STR("...)");
         {
            const fx_str_t strs_2[] = { slit_9, for_msg_prefix_0, slit_10, it_clause_0, slit_11, v_0, slit_12, v_1, slit_13 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_2, 9, &v_6), _fx_catch_1);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(for_loc_0, &v_6, &v_7, 0), _fx_catch_1);
         FX_THROW(&v_7, false, _fx_catch_1);
      }
      __fold_result___0 = ndims_i_0;

   _fx_catch_1: ;
      fx_free_exn(&v_7);
      FX_FREE_STR(&v_6);
      FX_FREE_STR(&v_5);
      FX_FREE_STR(&v_4);
      FX_FREE_STR(&it_clause_0);
      FX_FREE_STR(&v_3);
      FX_FREE_STR(&v_2);
      FX_FREE_STR(&for_msg_prefix_0);
      FX_FREE_STR(&v_1);
      FX_FREE_STR(&v_0);
      _fx_free_N13K_form__dom_t(&dom_i_0);
      FX_CHECK_EXN(_fx_cleanup);
   }
   *fx_result = __fold_result___0;

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM9gen_ccodeTa2LN15C_form__cstmt_t4LR17C_form__cmodule_tR17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
   struct _fx_LR17C_form__cmodule_t_data_t* cmods_0,
   struct _fx_R17K_form__kmodule_t* kmod_0,
   struct _fx_LN15C_form__cstmt_t_data_t* c_fdecls_0,
   struct _fx_LN15C_form__cstmt_t_data_t* mod_init_calls_0,
   struct _fx_Ta2LN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_LN14K_form__kexp_t km_top_0 = 0;
   fx_str_t km_cname_0 = {0};
   _fx_LN12Ast__scope_t mod_sc_0 = 0;
   _fx_LN14K_form__kexp_t top_code_0 = 0;
   _fx_rLN15C_form__cstmt_t top_inline_ccode_ref_0 = 0;
   _fx_rLN15C_form__cstmt_t fwd_fdecls_ref_0 = 0;
   _fx_rLN15C_form__cstmt_t glob_data_ccode_ref_0 = 0;
   _fx_rLN15C_form__cstmt_t module_cleanup_ref_0 = 0;
   _fx_Nt10Hashset__t1R9Ast__id_t defined_syms_arg_0 = 0;
   _fx_rNt10Hashset__t1R9Ast__id_t defined_syms_ref_0 = 0;
   _fx_N14C_form__cexp_t v_0 = 0;
   _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t i2e_arg_0 = 0;
   _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t i2e_ref_0 = 0;
   _fx_Nt10Hashset__t1R9Ast__id_t u1vals_0 = 0;
   _fx_rLrR23C_gen_code__block_ctx_t block_stack_ref_0 = 0;
   _fx_LS v_1 = 0;
   _fx_LS for_letters_0 = 0;
   _fx_ri return_used_ref_0 = 0;
   _fx_rNt6option1N14C_form__cexp_t func_dstexp_r_arg_0 = 0;
   _fx_rrNt6option1N14C_form__cexp_t func_dstexp_r_ref_0 = 0;
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t
      kexp2cexp_0 = {0};
   _fx_N14K_form__kexp_t v_2 = 0;
   _fx_R16Ast__val_flags_t v_3 = {0};
   _fx_N14C_form__cexp_t v_4 = 0;
   _fx_Nt6option1N14C_form__cexp_t v_5 = {0};
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_6 = {0};
   _fx_N14C_form__cexp_t status_exp_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_0 = 0;
   _fx_N14K_form__kexp_t v_7 = 0;
   _fx_rNt6option1N14C_form__cexp_t v_8 = 0;
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_9 = {0};
   _fx_N14C_form__cexp_t e_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_1 = 0;
   fx_str_t v_10 = {0};
   fx_str_t v_11 = {0};
   fx_str_t v_12 = {0};
   _fx_rR23C_gen_code__block_ctx_t v_13 = 0;
   _fx_LN15C_form__cstmt_t bctx_cleanup_0 = 0;
   _fx_LN15C_form__cstmt_t bctx_prologue_0 = 0;
   _fx_Ta2LN15C_form__cstmt_t __fold_result___0 = {0};
   _fx_Ta2LN15C_form__cstmt_t v_14 = {0};
   _fx_LN15C_form__cstmt_t global_vars_0 = 0;
   _fx_LN15C_form__cstmt_t temp_init_vals_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_2 = 0;
   _fx_LN15C_form__cstmt_t ccode_3 = 0;
   _fx_N15C_form__cstmt_t v_15 = 0;
   _fx_LN15C_form__cstmt_t ccode_4 = 0;
   _fx_LN15C_form__cstmt_t ccode_5 = 0;
   _fx_LN15C_form__cstmt_t deinit_ccode_0 = 0;
   _fx_Nt6option1N14C_form__cexp_t v_16 = {0};
   _fx_N15C_form__cstmt_t v_17 = 0;
   _fx_LN15C_form__cstmt_t ccode_6 = 0;
   fx_str_t km_cname_1 = {0};
   fx_str_t init_cname_0 = {0};
   _fx_LN15C_form__cstmt_t v_18 = 0;
   _fx_LN15C_form__cstmt_t v_19 = 0;
   _fx_LN15C_form__cstmt_t v_20 = 0;
   _fx_R17C_form__cdeffun_t v_21 = {0};
   _fx_rR17C_form__cdeffun_t init_f_0 = 0;
   fx_str_t deinit_cname_0 = {0};
   _fx_LN15C_form__cstmt_t v_22 = 0;
   _fx_R17C_form__cdeffun_t v_23 = {0};
   _fx_rR17C_form__cdeffun_t deinit_f_0 = 0;
   _fx_N15C_form__cinfo_t v_24 = {0};
   _fx_N15C_form__cinfo_t v_25 = {0};
   _fx_LS mod_names_0 = 0;
   _fx_LS v_26 = 0;
   _fx_LN15C_form__cstmt_t v_27 = 0;
   _fx_LN15C_form__cstmt_t v_28 = 0;
   _fx_LN15C_form__cstmt_t all_ccode_prologue_0 = 0;
   _fx_LN15C_form__cstmt_t v_29 = 0;
   _fx_LN15C_form__cstmt_t v_30 = 0;
   _fx_N15C_form__cstmt_t v_31 = 0;
   _fx_N15C_form__cstmt_t v_32 = 0;
   _fx_LN15C_form__cstmt_t v_33 = 0;
   _fx_LN15C_form__cstmt_t v_34 = 0;
   _fx_LN15C_form__cstmt_t v_35 = 0;
   _fx_LN15C_form__cstmt_t v_36 = 0;
   _fx_LN15C_form__cstmt_t v_37 = 0;
   _fx_LN15C_form__cstmt_t v_38 = 0;
   _fx_LN15C_form__cstmt_t all_ccode_0 = 0;
   int fx_status = 0;
   bool km_main_0 = kmod_0->km_main;
   FX_COPY_PTR(kmod_0->km_top, &km_top_0);
   fx_copy_str(&kmod_0->km_cname, &km_cname_0);
   int_ km_idx_0 = kmod_0->km_idx;
   _fx_R9Ast__id_t km_name_0 = kmod_0->km_name;
   _fx_N12Ast__scope_t v_39;
   _fx_M3AstFM8ScModuleN12Ast__scope_t1i(km_idx_0, &v_39);
   FX_CALL(_fx_cons_LN12Ast__scope_t(&v_39, 0, true, &mod_sc_0), _fx_cleanup);
   FX_COPY_PTR(km_top_0, &top_code_0);
   FX_CALL(_fx_make_rLN15C_form__cstmt_t(0, &top_inline_ccode_ref_0), _fx_cleanup);
   FX_CALL(_fx_make_rLN15C_form__cstmt_t(0, &fwd_fdecls_ref_0), _fx_cleanup);
   FX_CALL(_fx_make_rLN15C_form__cstmt_t(0, &glob_data_ccode_ref_0), _fx_cleanup);
   FX_CALL(_fx_make_rLN15C_form__cstmt_t(0, &module_cleanup_ref_0), _fx_cleanup);
   FX_CALL(_fx_M3AstFM16empty_id_hashsetNt10Hashset__t1RM4id_t1i(1024, &defined_syms_arg_0, 0), _fx_cleanup);
   FX_CALL(_fx_make_rNt10Hashset__t1R9Ast__id_t(defined_syms_arg_0, &defined_syms_ref_0), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(_fx_g19C_gen_code__CTypInt, &_fx_g10Ast__noloc,
         &v_0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM5emptyNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t3iR9Ast__id_tN14C_form__cexp_t(1024, &_fx_g9Ast__noid,
         v_0, &i2e_arg_0, 0), _fx_cleanup);
   FX_CALL(_fx_make_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(i2e_arg_0, &i2e_ref_0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM20find_single_use_valsNt10Hashset__t1R9Ast__id_t1LN14K_form__kexp_t(top_code_0, &u1vals_0, 0),
      _fx_cleanup);
   FX_CALL(_fx_make_rLrR23C_gen_code__block_ctx_t(0, &block_stack_ref_0), _fx_cleanup);
   fx_str_t slit_0 = FX_MAKE_STR("m");
   FX_CALL(_fx_cons_LS(&slit_0, 0, true, &v_1), _fx_cleanup);
   fx_str_t slit_1 = FX_MAKE_STR("l");
   FX_CALL(_fx_cons_LS(&slit_1, v_1, false, &v_1), _fx_cleanup);
   fx_str_t slit_2 = FX_MAKE_STR("k");
   FX_CALL(_fx_cons_LS(&slit_2, v_1, false, &v_1), _fx_cleanup);
   fx_str_t slit_3 = FX_MAKE_STR("j");
   FX_CALL(_fx_cons_LS(&slit_3, v_1, false, &v_1), _fx_cleanup);
   fx_str_t slit_4 = FX_MAKE_STR("i");
   FX_CALL(_fx_cons_LS(&slit_4, v_1, true, &for_letters_0), _fx_cleanup);
   _fx_R9Ast__id_t fx_status__0;
   fx_str_t slit_5 = FX_MAKE_STR("fx_status");
   FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_5, &fx_status__0, 0), _fx_cleanup);
   FX_CALL(_fx_make_ri(0, &return_used_ref_0), _fx_cleanup);
   FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &func_dstexp_r_arg_0), _fx_cleanup);
   FX_CALL(_fx_make_rrNt6option1N14C_form__cexp_t(func_dstexp_r_arg_0, &func_dstexp_r_ref_0), _fx_cleanup);
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &kexp2cexp_0);
   _fx_R10Ast__loc_t start_loc_0;
   if (top_code_0 == 0) {
      start_loc_0 = _fx_g10Ast__noloc;
   }
   else {
      FX_CALL(_fx_M10C_gen_codeFM2hdN14K_form__kexp_t1LN14K_form__kexp_t(top_code_0, &v_2, 0), _fx_cleanup);
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(v_2, &start_loc_0, 0), _fx_cleanup);
   }
   FX_CALL(
      _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
         &_fx_g28C_gen_code__BlockKind_Global, &start_loc_0, block_stack_ref_0, km_idx_0, 0), _fx_cleanup);
   _fx_R9Ast__id_t v_40;
   fx_str_t slit_6 = FX_MAKE_STR("fx_status");
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_6, &v_40, 0), _fx_cleanup);
   FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_3, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &start_loc_0, &v_4, 0), _fx_cleanup);
   _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_4, &v_5);
   fx_str_t slit_7 = FX_MAKE_STR("fx_status");
   FX_CALL(
      _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
         &v_40, _fx_g20C_gen_code__CTypCInt, &v_3, &slit_7, &v_5, 0, &start_loc_0, &v_6, 0), _fx_cleanup);
   FX_COPY_PTR(v_6.t0, &status_exp_0);
   FX_COPY_PTR(v_6.t1, &ccode_0);
   FX_CALL(_fx_M6K_formFM9code2kexpN14K_form__kexp_t2LN14K_form__kexp_tR10Ast__loc_t(top_code_0, &start_loc_0, &v_7, 0),
      _fx_cleanup);
   FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_8), _fx_cleanup);
   FX_CALL(
      kexp2cexp_0.fp(v_7, v_8, ccode_0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
         fwd_fdecls_ref_0, &fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
         return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_9, kexp2cexp_0.fcv), _fx_cleanup);
   FX_COPY_PTR(v_9.t0, &e_0);
   FX_COPY_PTR(v_9.t1, &ccode_1);
   FX_CALL(_fx_M3AstFM2ppS1RM4id_t(&km_name_0, &v_10, 0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_10, &v_11, 0), _fx_cleanup);
   fx_str_t slit_8 = FX_MAKE_STR("\t\'");
   fx_str_t slit_9 = FX_MAKE_STR("\' has been translated to C. Finalizing the produced code ...");
   {
      const fx_str_t strs_0[] = { slit_8, v_11, slit_9 };
      FX_CALL(fx_strjoin(0, 0, 0, strs_0, 3, &v_12), _fx_cleanup);
   }
   FX_CALL(_fx_M3AstFM10pr_verbosev1S(&v_12, 0), _fx_cleanup);
   _fx_R10Ast__loc_t end_loc_0;
   FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(e_0, &end_loc_0, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&end_loc_0, block_stack_ref_0, &v_13,
         0), _fx_cleanup);
   _fx_R23C_gen_code__block_ctx_t* v_41 = &v_13->data;
   int_ bctx_label_used_0 = v_41->bctx_label_used;
   FX_COPY_PTR(v_41->bctx_cleanup, &bctx_cleanup_0);
   _fx_R9Ast__id_t bctx_label_0 = v_41->bctx_label;
   FX_COPY_PTR(v_41->bctx_prologue, &bctx_prologue_0);
   _fx_make_Ta2LN15C_form__cstmt_t(0, 0, &__fold_result___0);
   _fx_LN15C_form__cstmt_t lst_0 = bctx_prologue_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_Ta2LN15C_form__cstmt_t v_42 = {0};
      _fx_LN15C_form__cstmt_t global_vars_1 = 0;
      _fx_LN15C_form__cstmt_t temp_init_vals_1 = 0;
      _fx_Ta2LN15C_form__cstmt_t v_43 = {0};
      _fx_LN15C_form__cstmt_t v_44 = 0;
      _fx_LN15C_form__cstmt_t v_45 = 0;
      _fx_N15C_form__cstmt_t s_0 = lst_0->hd;
      _fx_copy_Ta2LN15C_form__cstmt_t(&__fold_result___0, &v_42);
      FX_COPY_PTR(v_42.t0, &global_vars_1);
      FX_COPY_PTR(v_42.t1, &temp_init_vals_1);
      bool is_global_0;
      if (FX_REC_VARIANT_TAG(s_0) == 16) {
         _fx_N15C_form__cinfo_t v_46 = {0};
         _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t* vcase_0 = &s_0->u.CDefVal;
         FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(&vcase_0->t1, &vcase_0->t3, &v_46, 0),
            _fx_catch_0);
         if (v_46.tag == 2) {
            _fx_R16Ast__val_flags_t* cv_flags_0 = &v_46.u.CVal.cv_flags;
            bool t_0;
            if (cv_flags_0->val_flag_temp) {
               t_0 = true;
            }
            else {
               t_0 = cv_flags_0->val_flag_tempref;
            }
            is_global_0 = !t_0;
         }
         else {
            is_global_0 = true;
         }
         FX_CHECK_EXN(_fx_catch_0);

      _fx_catch_0: ;
         _fx_free_N15C_form__cinfo_t(&v_46);
      }
      else {
         is_global_0 = true;
      }
      FX_CHECK_EXN(_fx_catch_1);
      if (is_global_0) {
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(s_0, global_vars_1, true, &v_44), _fx_catch_1);
         _fx_make_Ta2LN15C_form__cstmt_t(v_44, temp_init_vals_1, &v_43);
      }
      else {
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(s_0, temp_init_vals_1, true, &v_45), _fx_catch_1);
         _fx_make_Ta2LN15C_form__cstmt_t(global_vars_1, v_45, &v_43);
      }
      _fx_free_Ta2LN15C_form__cstmt_t(&__fold_result___0);
      _fx_copy_Ta2LN15C_form__cstmt_t(&v_43, &__fold_result___0);

   _fx_catch_1: ;
      if (v_45) {
         _fx_free_LN15C_form__cstmt_t(&v_45);
      }
      if (v_44) {
         _fx_free_LN15C_form__cstmt_t(&v_44);
      }
      _fx_free_Ta2LN15C_form__cstmt_t(&v_43);
      if (temp_init_vals_1) {
         _fx_free_LN15C_form__cstmt_t(&temp_init_vals_1);
      }
      if (global_vars_1) {
         _fx_free_LN15C_form__cstmt_t(&global_vars_1);
      }
      _fx_free_Ta2LN15C_form__cstmt_t(&v_42);
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_Ta2LN15C_form__cstmt_t(&__fold_result___0, &v_14);
   FX_COPY_PTR(v_14.t0, &global_vars_0);
   FX_COPY_PTR(v_14.t1, &temp_init_vals_0);
   FX_CALL(_fx_M10C_gen_codeFM13pop_block_ctxv2R10Ast__loc_trLrRM11block_ctx_t(&end_loc_0, block_stack_ref_0, 0), _fx_cleanup);
   int tag_0 = FX_REC_VARIANT_TAG(e_0);
   bool res_0;
   if (tag_0 == 1) {
      res_0 = true;
   }
   else if (tag_0 == 2) {
      res_0 = true;
   }
   else {
      res_0 = false;
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (res_0) {
      FX_COPY_PTR(ccode_1, &ccode_2); goto _fx_endmatch_0;
   }
   _fx_N15C_form__cstmt_t v_47 = 0;
   FX_CALL(_fx_M6C_formFM9cexp2stmtN15C_form__cstmt_t1N14C_form__cexp_t(e_0, &v_47, 0), _fx_catch_2);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_47, ccode_1, true, &ccode_2), _fx_catch_2);

_fx_catch_2: ;
   if (v_47) {
      _fx_free_N15C_form__cstmt_t(&v_47);
   }

_fx_endmatch_0: ;
   FX_CHECK_EXN(_fx_cleanup);
   if (bctx_label_used_0 == 0) {
      FX_COPY_PTR(ccode_2, &ccode_3);
   }
   else {
      FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&bctx_label_0, &end_loc_0, &v_15),
         _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_15, ccode_2, true, &ccode_3), _fx_cleanup);
   }
   FX_CALL(_fx_M6C_formFM15filter_out_nopsLN15C_form__cstmt_t1LN15C_form__cstmt_t(ccode_3, &ccode_4, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(bctx_cleanup_0, ccode_4, &ccode_5,
         0), _fx_cleanup);
   FX_COPY_PTR(module_cleanup_ref_0->data, &deinit_ccode_0);
   _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(status_exp_0, &v_16);
   FX_CALL(_fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_16, &end_loc_0, &v_17),
      _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_17, ccode_5, true, &ccode_6), _fx_cleanup);
   FX_CALL(_fx_M8K_mangleFM12mangle_mnameS1S(&km_cname_0, &km_cname_1, 0), _fx_cleanup);
   fx_str_t slit_10 = FX_MAKE_STR("fx_init_");
   {
      const fx_str_t strs_1[] = { slit_10, km_cname_1 };
      FX_CALL(fx_strjoin(0, 0, 0, strs_1, 2, &init_cname_0), _fx_cleanup);
   }
   _fx_R9Ast__id_t init_name_0;
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &init_cname_0, &init_name_0, 0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(ccode_6, &v_18, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(mod_init_calls_0, v_18, &v_19, 0),
      _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(temp_init_vals_0, v_19, &v_20, 0),
      _fx_cleanup);
   _fx_R16Ast__fun_flags_t v_48;
   FX_CALL(_fx_M3AstFM17default_fun_flagsRM11fun_flags_t0(&v_48, 0), _fx_cleanup);
   _fx_make_R17C_form__cdeffun_t(&init_name_0, &init_cname_0, 0, _fx_g20C_gen_code__CTypCInt, v_20, &v_48, 0, &end_loc_0,
      &v_21);
   FX_CALL(_fx_make_rR17C_form__cdeffun_t(&v_21, &init_f_0), _fx_cleanup);
   fx_str_t slit_11 = FX_MAKE_STR("fx_deinit_");
   {
      const fx_str_t strs_2[] = { slit_11, km_cname_1 };
      FX_CALL(fx_strjoin(0, 0, 0, strs_2, 2, &deinit_cname_0), _fx_cleanup);
   }
   _fx_R9Ast__id_t deinit_name_0;
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &deinit_cname_0, &deinit_name_0, 0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(deinit_ccode_0, &v_22, 0), _fx_cleanup);
   _fx_R16Ast__fun_flags_t v_49;
   FX_CALL(_fx_M3AstFM17default_fun_flagsRM11fun_flags_t0(&v_49, 0), _fx_cleanup);
   _fx_make_R17C_form__cdeffun_t(&deinit_name_0, &deinit_cname_0, 0, _fx_g20C_gen_code__CTypVoid, v_22, &v_49, 0, &end_loc_0,
      &v_23);
   FX_CALL(_fx_make_rR17C_form__cdeffun_t(&v_23, &deinit_f_0), _fx_cleanup);
   _fx_M6C_formFM4CFunN15C_form__cinfo_t1rRM9cdeffun_t(init_f_0, &v_24);
   FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(&init_name_0, &v_24, 0), _fx_cleanup);
   _fx_M6C_formFM4CFunN15C_form__cinfo_t1rRM9cdeffun_t(deinit_f_0, &v_25);
   FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(&deinit_name_0, &v_25, 0), _fx_cleanup);
   if (km_main_0) {
      _fx_LS lstend_0 = 0;
      _fx_LR17C_form__cmodule_t lst_1 = cmods_0;
      for (; lst_1; lst_1 = lst_1->tl) {
         _fx_R17C_form__cmodule_t* __pat___0 = &lst_1->hd;
         _fx_LS node_0 = 0;
         FX_CALL(_fx_cons_LS(&__pat___0->cmod_cname, 0, false, &node_0), _fx_catch_3);
         FX_LIST_APPEND(v_26, lstend_0, node_0);

      _fx_catch_3: ;
         FX_CHECK_EXN(_fx_cleanup);
      }
      FX_CALL(_fx_cons_LS(&km_cname_1, v_26, true, &mod_names_0), _fx_cleanup);
   }
   FX_CALL(_fx_M10C_gen_codeFM18gen_ccode_prologueLN15C_form__cstmt_t2BR10Ast__loc_t(km_main_0, &start_loc_0, &v_27, 0),
      _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(top_inline_ccode_ref_0->data, &v_28, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_27, v_28, &all_ccode_prologue_0,
         0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(fwd_fdecls_ref_0->data, &v_29, 0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(glob_data_ccode_ref_0->data, &v_30, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM7CDefFunN15C_form__cstmt_t1rRM9cdeffun_t(init_f_0, &v_31), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM7CDefFunN15C_form__cstmt_t1rRM9cdeffun_t(deinit_f_0, &v_32), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_32, 0, true, &v_33), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_31, v_33, false, &v_33), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM8gen_mainLN15C_form__cstmt_t3BLSR10Ast__loc_t(km_main_0, mod_names_0, &end_loc_0, &v_34, 0),
      _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_33, v_34, &v_35, 0),
      _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(c_fdecls_0, v_35, &v_36, 0),
      _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_30, v_36, &v_37, 0),
      _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_29, v_37, &v_38, 0),
      _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(global_vars_0, v_38, &all_ccode_0,
         0), _fx_cleanup);
   _fx_make_Ta2LN15C_form__cstmt_t(all_ccode_prologue_0, all_ccode_0, fx_result);

_fx_cleanup: ;
   if (km_top_0) {
      _fx_free_LN14K_form__kexp_t(&km_top_0);
   }
   FX_FREE_STR(&km_cname_0);
   FX_FREE_LIST_SIMPLE(&mod_sc_0);
   if (top_code_0) {
      _fx_free_LN14K_form__kexp_t(&top_code_0);
   }
   if (top_inline_ccode_ref_0) {
      _fx_free_rLN15C_form__cstmt_t(&top_inline_ccode_ref_0);
   }
   if (fwd_fdecls_ref_0) {
      _fx_free_rLN15C_form__cstmt_t(&fwd_fdecls_ref_0);
   }
   if (glob_data_ccode_ref_0) {
      _fx_free_rLN15C_form__cstmt_t(&glob_data_ccode_ref_0);
   }
   if (module_cleanup_ref_0) {
      _fx_free_rLN15C_form__cstmt_t(&module_cleanup_ref_0);
   }
   if (defined_syms_arg_0) {
      _fx_free_Nt10Hashset__t1R9Ast__id_t(&defined_syms_arg_0);
   }
   if (defined_syms_ref_0) {
      _fx_free_rNt10Hashset__t1R9Ast__id_t(&defined_syms_ref_0);
   }
   if (v_0) {
      _fx_free_N14C_form__cexp_t(&v_0);
   }
   if (i2e_arg_0) {
      _fx_free_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&i2e_arg_0);
   }
   if (i2e_ref_0) {
      _fx_free_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(&i2e_ref_0);
   }
   if (u1vals_0) {
      _fx_free_Nt10Hashset__t1R9Ast__id_t(&u1vals_0);
   }
   if (block_stack_ref_0) {
      _fx_free_rLrR23C_gen_code__block_ctx_t(&block_stack_ref_0);
   }
   if (v_1) {
      _fx_free_LS(&v_1);
   }
   if (for_letters_0) {
      _fx_free_LS(&for_letters_0);
   }
   FX_FREE_REF_SIMPLE(&return_used_ref_0);
   if (func_dstexp_r_arg_0) {
      _fx_free_rNt6option1N14C_form__cexp_t(&func_dstexp_r_arg_0);
   }
   if (func_dstexp_r_ref_0) {
      _fx_free_rrNt6option1N14C_form__cexp_t(&func_dstexp_r_ref_0);
   }
   FX_FREE_FP(&kexp2cexp_0);
   if (v_2) {
      _fx_free_N14K_form__kexp_t(&v_2);
   }
   _fx_free_R16Ast__val_flags_t(&v_3);
   if (v_4) {
      _fx_free_N14C_form__cexp_t(&v_4);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&v_5);
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_6);
   if (status_exp_0) {
      _fx_free_N14C_form__cexp_t(&status_exp_0);
   }
   if (ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&ccode_0);
   }
   if (v_7) {
      _fx_free_N14K_form__kexp_t(&v_7);
   }
   if (v_8) {
      _fx_free_rNt6option1N14C_form__cexp_t(&v_8);
   }
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_9);
   if (e_0) {
      _fx_free_N14C_form__cexp_t(&e_0);
   }
   if (ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&ccode_1);
   }
   FX_FREE_STR(&v_10);
   FX_FREE_STR(&v_11);
   FX_FREE_STR(&v_12);
   if (v_13) {
      _fx_free_rR23C_gen_code__block_ctx_t(&v_13);
   }
   if (bctx_cleanup_0) {
      _fx_free_LN15C_form__cstmt_t(&bctx_cleanup_0);
   }
   if (bctx_prologue_0) {
      _fx_free_LN15C_form__cstmt_t(&bctx_prologue_0);
   }
   _fx_free_Ta2LN15C_form__cstmt_t(&__fold_result___0);
   _fx_free_Ta2LN15C_form__cstmt_t(&v_14);
   if (global_vars_0) {
      _fx_free_LN15C_form__cstmt_t(&global_vars_0);
   }
   if (temp_init_vals_0) {
      _fx_free_LN15C_form__cstmt_t(&temp_init_vals_0);
   }
   if (ccode_2) {
      _fx_free_LN15C_form__cstmt_t(&ccode_2);
   }
   if (ccode_3) {
      _fx_free_LN15C_form__cstmt_t(&ccode_3);
   }
   if (v_15) {
      _fx_free_N15C_form__cstmt_t(&v_15);
   }
   if (ccode_4) {
      _fx_free_LN15C_form__cstmt_t(&ccode_4);
   }
   if (ccode_5) {
      _fx_free_LN15C_form__cstmt_t(&ccode_5);
   }
   if (deinit_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&deinit_ccode_0);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&v_16);
   if (v_17) {
      _fx_free_N15C_form__cstmt_t(&v_17);
   }
   if (ccode_6) {
      _fx_free_LN15C_form__cstmt_t(&ccode_6);
   }
   FX_FREE_STR(&km_cname_1);
   FX_FREE_STR(&init_cname_0);
   if (v_18) {
      _fx_free_LN15C_form__cstmt_t(&v_18);
   }
   if (v_19) {
      _fx_free_LN15C_form__cstmt_t(&v_19);
   }
   if (v_20) {
      _fx_free_LN15C_form__cstmt_t(&v_20);
   }
   _fx_free_R17C_form__cdeffun_t(&v_21);
   if (init_f_0) {
      _fx_free_rR17C_form__cdeffun_t(&init_f_0);
   }
   FX_FREE_STR(&deinit_cname_0);
   if (v_22) {
      _fx_free_LN15C_form__cstmt_t(&v_22);
   }
   _fx_free_R17C_form__cdeffun_t(&v_23);
   if (deinit_f_0) {
      _fx_free_rR17C_form__cdeffun_t(&deinit_f_0);
   }
   _fx_free_N15C_form__cinfo_t(&v_24);
   _fx_free_N15C_form__cinfo_t(&v_25);
   if (mod_names_0) {
      _fx_free_LS(&mod_names_0);
   }
   if (v_26) {
      _fx_free_LS(&v_26);
   }
   if (v_27) {
      _fx_free_LN15C_form__cstmt_t(&v_27);
   }
   if (v_28) {
      _fx_free_LN15C_form__cstmt_t(&v_28);
   }
   if (all_ccode_prologue_0) {
      _fx_free_LN15C_form__cstmt_t(&all_ccode_prologue_0);
   }
   if (v_29) {
      _fx_free_LN15C_form__cstmt_t(&v_29);
   }
   if (v_30) {
      _fx_free_LN15C_form__cstmt_t(&v_30);
   }
   if (v_31) {
      _fx_free_N15C_form__cstmt_t(&v_31);
   }
   if (v_32) {
      _fx_free_N15C_form__cstmt_t(&v_32);
   }
   if (v_33) {
      _fx_free_LN15C_form__cstmt_t(&v_33);
   }
   if (v_34) {
      _fx_free_LN15C_form__cstmt_t(&v_34);
   }
   if (v_35) {
      _fx_free_LN15C_form__cstmt_t(&v_35);
   }
   if (v_36) {
      _fx_free_LN15C_form__cstmt_t(&v_36);
   }
   if (v_37) {
      _fx_free_LN15C_form__cstmt_t(&v_37);
   }
   if (v_38) {
      _fx_free_LN15C_form__cstmt_t(&v_38);
   }
   if (all_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&all_ccode_0);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM14make_fx_statusN14C_form__cexp_t2R10Ast__loc_tR9Ast__id_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   FX_CALL(
      _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(fx_status__0,
         _fx_g20C_gen_code__CTypCInt, loc_0, fx_result, 0), _fx_cleanup);

_fx_cleanup: ;
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM33ensure_sym_is_defined_or_declaredv4R9Ast__id_tR10Ast__loc_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_t(
   struct _fx_R9Ast__id_t* f_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   void* fx_fv)
{
   _fx_N15C_form__cstmt_t v_0 = 0;
   _fx_LN15C_form__cstmt_t v_1 = 0;
   int fx_status = 0;
   _fx_Nt10Hashset__t1R9Ast__id_t* defined_syms_0 = &defined_syms_ref_0->data;
   _fx_LN15C_form__cstmt_t* fwd_fdecls_0 = &fwd_fdecls_ref_0->data;
   uint64_t __fold_result___0 = 14695981039346656037ULL;
   uint64_t h_0 = __fold_result___0 ^ ((uint64_t)f_0->m ^ 14695981039346656037ULL);
   __fold_result___0 = h_0 * 1099511628211ULL;
   uint64_t h_1 = __fold_result___0 ^ ((uint64_t)f_0->i ^ 14695981039346656037ULL);
   __fold_result___0 = h_1 * 1099511628211ULL;
   uint64_t h_2 = __fold_result___0 ^ ((uint64_t)f_0->j ^ 14695981039346656037ULL);
   __fold_result___0 = h_2 * 1099511628211ULL;
   _fx_Ta2i v_2;
   FX_CALL(
      _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*defined_syms_0, f_0,
         __fold_result___0 & 9223372036854775807ULL, &v_2, 0), _fx_cleanup);
   if (!(v_2.t1 >= 0)) {
      uint64_t __fold_result___1 = 14695981039346656037ULL;
      uint64_t h_3 = __fold_result___1 ^ ((uint64_t)f_0->m ^ 14695981039346656037ULL);
      __fold_result___1 = h_3 * 1099511628211ULL;
      uint64_t h_4 = __fold_result___1 ^ ((uint64_t)f_0->i ^ 14695981039346656037ULL);
      __fold_result___1 = h_4 * 1099511628211ULL;
      uint64_t h_5 = __fold_result___1 ^ ((uint64_t)f_0->j ^ 14695981039346656037ULL);
      __fold_result___1 = h_5 * 1099511628211ULL;
      FX_CALL(
         _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*defined_syms_0, f_0,
            __fold_result___1 & 9223372036854775807ULL, 0), _fx_cleanup);
      FX_CALL(_fx_M6C_formFM14CDefForwardSymN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(f_0, loc_0, &v_0), _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_0, *fwd_fdecls_0, true, &v_1), _fx_cleanup);
      _fx_free_LN15C_form__cstmt_t(fwd_fdecls_0);
      FX_COPY_PTR(v_1, fwd_fdecls_0);
   }

_fx_cleanup: ;
   if (v_0) {
      _fx_free_N15C_form__cstmt_t(&v_0);
   }
   if (v_1) {
      _fx_free_LN15C_form__cstmt_t(&v_1);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM17check_inside_loopv3BR10Ast__loc_trLrRM11block_ctx_t(
   bool is_break_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   void* fx_fv)
{
   fx_str_t bc_str_0 = {0};
   int fx_status = 0;
   if (is_break_0) {
      fx_str_t slit_0 = FX_MAKE_STR("break"); fx_copy_str(&slit_0, &bc_str_0);
   }
   else {
      fx_str_t slit_1 = FX_MAKE_STR("continue"); fx_copy_str(&slit_1, &bc_str_0);
   }
   FX_CALL(
      _fx_M10C_gen_codeFM18check_inside_loop_v4LrRM11block_ctx_tSBR10Ast__loc_t(block_stack_ref_0->data, &bc_str_0, is_break_0,
         loc_0, 0), _fx_cleanup);

_fx_cleanup: ;
   FX_FREE_STR(&bc_str_0);
   return fx_status;
}

static int _fx_M10C_gen_codeFM18check_inside_loop_v4LrRM11block_ctx_tSBR10Ast__loc_t(
   struct _fx_LrR23C_gen_code__block_ctx_t_data_t* s_0,
   fx_str_t* bc_str_0,
   bool is_break_0,
   struct _fx_R10Ast__loc_t* loc_0,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t s_1 = 0;
   int fx_status = 0;
   FX_COPY_PTR(s_0, &s_1);
   for (;;) {
      _fx_LrR23C_gen_code__block_ctx_t s_2 = 0;
      FX_COPY_PTR(s_1, &s_2);
      if (s_2 != 0) {
         _fx_LrR23C_gen_code__block_ctx_t rest_0 = s_2->tl;
         _fx_rR23C_gen_code__block_ctx_t top_0 = s_2->hd;
         _fx_R23C_gen_code__block_ctx_t* v_0 = &top_0->data;
         _fx_R16Ast__for_flags_t bctx_for_flags_0 = v_0->bctx_for_flags;
         _fx_N24C_gen_code__block_kind_t bctx_kind_0 = v_0->bctx_kind;
         int tag_0 = bctx_kind_0.tag;
         bool res_0;
         if (tag_0 == 5) {
            res_0 = true;
         }
         else if (tag_0 == 6) {
            res_0 = true;
         }
         else {
            res_0 = false;
         }
         FX_CHECK_EXN(_fx_catch_2);
         if (res_0) {
            if (bctx_for_flags_0.for_flag_nested) {
               _fx_free_LrR23C_gen_code__block_ctx_t(&s_1); FX_COPY_PTR(rest_0, &s_1);
            }
            else if (is_break_0) {
               top_0->data.bctx_break_used = top_0->data.bctx_break_used + 1; FX_BREAK(_fx_catch_0);
            }
            else {
               top_0->data.bctx_continue_used = top_0->data.bctx_continue_used + 1; FX_BREAK(_fx_catch_0);
            }

         _fx_catch_0: ;
            goto _fx_endmatch_0;
         }
         bool res_1;
         if (tag_0 == 2) {
            res_1 = true;
         }
         else if (tag_0 == 1) {
            res_1 = true;
         }
         else {
            res_1 = false;
         }
         FX_CHECK_EXN(_fx_catch_2);
         if (res_1) {
            fx_str_t v_1 = {0};
            fx_exn_t v_2 = {0};
            fx_str_t slit_0 = FX_MAKE_STR("\'");
            fx_str_t slit_1 = FX_MAKE_STR("\' is used outside of a loop");
            {
               const fx_str_t strs_0[] = { slit_0, *bc_str_0, slit_1 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_0, 3, &v_1), _fx_catch_1);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_1, &v_2, 0), _fx_catch_1);
            FX_THROW(&v_2, false, _fx_catch_1);

         _fx_catch_1: ;
            fx_free_exn(&v_2);
            FX_FREE_STR(&v_1);
            goto _fx_endmatch_0;
         }
         _fx_free_LrR23C_gen_code__block_ctx_t(&s_1);
         FX_COPY_PTR(rest_0, &s_1);

      _fx_endmatch_0: ;
         FX_CHECK_EXN(_fx_catch_2);

      _fx_catch_2: ;
      }
      else {
         fx_str_t v_3 = {0};
         fx_exn_t v_4 = {0};
         fx_str_t slit_2 = FX_MAKE_STR("\'");
         fx_str_t slit_3 = FX_MAKE_STR("\' is used outside of a loop");
         {
            const fx_str_t strs_1[] = { slit_2, *bc_str_0, slit_3 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_1, 3, &v_3), _fx_catch_3);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_3, &v_4, 0), _fx_catch_3);
         FX_THROW(&v_4, false, _fx_catch_3);

      _fx_catch_3: ;
         fx_free_exn(&v_4);
         FX_FREE_STR(&v_3);
      }
      FX_CHECK_EXN(_fx_catch_4);

   _fx_catch_4: ;
      if (s_2) {
         _fx_free_LrR23C_gen_code__block_ctx_t(&s_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }

_fx_cleanup: ;
   if (s_1) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&s_1);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rR23C_gen_code__block_ctx_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   int fx_status = 0;
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, fx_result);
   }
   else {
      fx_exn_t v_0 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_0, 0), _fx_catch_0);
      FX_THROW(&v_0, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_0);
   }
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM9curr_funcR9Ast__id_t2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv)
{
   _fx_Nt6option1rR23C_gen_code__block_ctx_t __fold_result___0 = {0};
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_Nt6option1rR23C_gen_code__block_ctx_t __fold_result___1 = {0};
   _fx_R23C_gen_code__block_ctx_t v_0 = {0};
   int fx_status = 0;
   _fx_copy_Nt6option1rR23C_gen_code__block_ctx_t(&_fx_g16C_gen_code__None, &__fold_result___0);
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   _fx_LrR23C_gen_code__block_ctx_t lst_0 = block_stack_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_Nt6option1rR23C_gen_code__block_ctx_t v_1 = {0};
      _fx_rR23C_gen_code__block_ctx_t bctx_0 = lst_0->hd;
      _fx_N24C_gen_code__block_kind_t v_2 = bctx_0->data.bctx_kind;
      bool res_0;
      if (v_2.tag == 2) {
         res_0 = true;
      }
      else {
         res_0 = false;
      }
      FX_CHECK_EXN(_fx_catch_0);
      if (res_0) {
         _fx_M10C_gen_codeFM4SomeNt6option1rRM11block_ctx_t1rRM11block_ctx_t(bctx_0, &v_1);
         _fx_free_Nt6option1rR23C_gen_code__block_ctx_t(&__fold_result___0);
         _fx_copy_Nt6option1rR23C_gen_code__block_ctx_t(&v_1, &__fold_result___0);
         FX_BREAK(_fx_catch_0);
      }

   _fx_catch_0: ;
      _fx_free_Nt6option1rR23C_gen_code__block_ctx_t(&v_1);
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_Nt6option1rR23C_gen_code__block_ctx_t(&__fold_result___0, &__fold_result___1);
   if (__fold_result___1.tag == 2) {
      _fx_copy_R23C_gen_code__block_ctx_t(&__fold_result___1.u.Some->data, &v_0);
      _fx_N24C_gen_code__block_kind_t* v_3 = &v_0.bctx_kind;
      if (v_3->tag == 2) {
         *fx_result = v_3->u.BlockKind_Fun; goto _fx_endmatch_0;
      }
   }
   *fx_result = _fx_g9Ast__noid;

_fx_endmatch_0: ;

_fx_cleanup: ;
   _fx_free_Nt6option1rR23C_gen_code__block_ctx_t(&__fold_result___0);
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   _fx_free_Nt6option1rR23C_gen_code__block_ctx_t(&__fold_result___1);
   _fx_free_R23C_gen_code__block_ctx_t(&v_0);
   return fx_status;
}

static int _fx_M10C_gen_codeFM14new_block_ctx_v5N24C_gen_code__block_kind_tR16Ast__for_flags_tR10Ast__loc_trLrRM11block_ctx_ti(
   struct _fx_N24C_gen_code__block_kind_t* kind_0,
   struct _fx_R16Ast__for_flags_t* for_flags_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   int_ km_idx_0,
   void* fx_fv)
{
   fx_str_t l_basename_0 = {0};
   fx_str_t basename_0 = {0};
   fx_str_t cname_0 = {0};
   _fx_R19C_form__cdeflabel_t v_0 = {0};
   _fx_N15C_form__cinfo_t v_1 = {0};
   fx_str_t basename_1 = {0};
   fx_str_t cname_1 = {0};
   _fx_R19C_form__cdeflabel_t v_2 = {0};
   _fx_N15C_form__cinfo_t v_3 = {0};
   _fx_N14C_form__cexp_t v_4 = 0;
   _fx_N14C_form__cexp_t v_5 = 0;
   _fx_R23C_gen_code__block_ctx_t v_6 = {0};
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_LrR23C_gen_code__block_ctx_t v_7 = 0;
   int fx_status = 0;
   _fx_LrR23C_gen_code__block_ctx_t* block_stack_0 = &block_stack_ref_0->data;
   int tag_0 = kind_0->tag;
   bool res_0;
   if (tag_0 == 1) {
      res_0 = true;
   }
   else if (tag_0 == 2) {
      res_0 = true;
   }
   else {
      res_0 = false;
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (res_0) {
      fx_str_t slit_0 = FX_MAKE_STR("cleanup"); fx_copy_str(&slit_0, &l_basename_0); goto _fx_endmatch_0;
   }
   fx_str_t slit_1 = FX_MAKE_STR("catch");
   fx_copy_str(&slit_1, &l_basename_0);

_fx_endmatch_0: ;
   FX_CHECK_EXN(_fx_cleanup);
   _fx_R10Ast__loc_t v_8;
   FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(loc_0, &v_8, 0), _fx_cleanup);
   bool v_9;
   fx_str_t slit_2 = FX_MAKE_STR("_fx_");
   v_9 = _fx_M6StringFM10startswithB2SS(&l_basename_0, &slit_2, 0);
   if (v_9) {
      fx_copy_str(&l_basename_0, &basename_0);
   }
   else {
      fx_str_t slit_3 = FX_MAKE_STR("_fx_");
      {
         const fx_str_t strs_0[] = { slit_3, l_basename_0 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_0, 2, &basename_0), _fx_cleanup);
      }
   }
   _fx_R9Ast__id_t li_0;
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &basename_0, &li_0, 0), _fx_cleanup);
   bool v_10;
   fx_str_t slit_4 = FX_MAKE_STR("_fx_cleanup");
   v_10 = _fx_F6__eq__B2SS(&basename_0, &slit_4, 0);
   if (v_10) {
      fx_copy_str(&basename_0, &cname_0);
   }
   else {
      fx_str_t slit_5 = FX_MAKE_STR(""); fx_copy_str(&slit_5, &cname_0);
   }
   _fx_make_R19C_form__cdeflabel_t(&li_0, &cname_0, &v_8, &v_0);
   _fx_M6C_formFM6CLabelN15C_form__cinfo_t1RM11cdeflabel_t(&v_0, &v_1);
   FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(&li_0, &v_1, 0), _fx_cleanup);
   _fx_R9Ast__id_t br_l_0;
   if (kind_0->tag != 6) {
      br_l_0 = _fx_g9Ast__noid;
   }
   else {
      _fx_R10Ast__loc_t v_11;
      FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(loc_0, &v_11, 0), _fx_cleanup);
      bool v_12;
      fx_str_t slit_6 = FX_MAKE_STR("break");
      fx_str_t slit_7 = FX_MAKE_STR("_fx_");
      v_12 = _fx_M6StringFM10startswithB2SS(&slit_6, &slit_7, 0);
      if (v_12) {
         fx_str_t slit_8 = FX_MAKE_STR("break"); fx_copy_str(&slit_8, &basename_1);
      }
      else {
         fx_str_t slit_9 = FX_MAKE_STR("_fx_break"); fx_copy_str(&slit_9, &basename_1);
      }
      _fx_R9Ast__id_t li_1;
      FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &basename_1, &li_1, 0), _fx_cleanup);
      bool v_13;
      fx_str_t slit_10 = FX_MAKE_STR("_fx_cleanup");
      v_13 = _fx_F6__eq__B2SS(&basename_1, &slit_10, 0);
      if (v_13) {
         fx_copy_str(&basename_1, &cname_1);
      }
      else {
         fx_str_t slit_11 = FX_MAKE_STR(""); fx_copy_str(&slit_11, &cname_1);
      }
      _fx_make_R19C_form__cdeflabel_t(&li_1, &cname_1, &v_11, &v_2);
      _fx_M6C_formFM6CLabelN15C_form__cinfo_t1RM11cdeflabel_t(&v_2, &v_3);
      FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(&li_1, &v_3, 0), _fx_cleanup);
      br_l_0 = li_1;
   }
   FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_4, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_5, 0), _fx_cleanup);
   _fx_make_R23C_gen_code__block_ctx_t(kind_0, &li_0, &br_l_0, for_flags_0, v_4, v_5, 0, 0, 0, 0, 0, 0, &v_6);
   FX_CALL(_fx_make_rR23C_gen_code__block_ctx_t(&v_6, &bctx_0), _fx_cleanup);
   FX_CALL(_fx_cons_LrR23C_gen_code__block_ctx_t(bctx_0, *block_stack_0, true, &v_7), _fx_cleanup);
   _fx_free_LrR23C_gen_code__block_ctx_t(block_stack_0);
   FX_COPY_PTR(v_7, block_stack_0);

_fx_cleanup: ;
   FX_FREE_STR(&l_basename_0);
   FX_FREE_STR(&basename_0);
   FX_FREE_STR(&cname_0);
   _fx_free_R19C_form__cdeflabel_t(&v_0);
   _fx_free_N15C_form__cinfo_t(&v_1);
   FX_FREE_STR(&basename_1);
   FX_FREE_STR(&cname_1);
   _fx_free_R19C_form__cdeflabel_t(&v_2);
   _fx_free_N15C_form__cinfo_t(&v_3);
   if (v_4) {
      _fx_free_N14C_form__cexp_t(&v_4);
   }
   if (v_5) {
      _fx_free_N14C_form__cexp_t(&v_5);
   }
   _fx_free_R23C_gen_code__block_ctx_t(&v_6);
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (v_7) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&v_7);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
   struct _fx_N24C_gen_code__block_kind_t* kind_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   int_ km_idx_0,
   void* fx_fv)
{
   int fx_status = 0;
   _fx_R16Ast__for_flags_t v_0;
   FX_CALL(_fx_M3AstFM17default_for_flagsRM11for_flags_t0(&v_0, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM14new_block_ctx_v5N24C_gen_code__block_kind_tR16Ast__for_flags_tR10Ast__loc_trLrRM11block_ctx_ti(
         kind_0, &v_0, loc_0, block_stack_ref_0, km_idx_0, 0), _fx_cleanup);

_fx_cleanup: ;
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM17new_for_block_ctxv7iR16Ast__for_flags_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_trLrRM11block_ctx_ti(
   int_ ndims_0,
   struct _fx_R16Ast__for_flags_t* for_flags_0,
   struct _fx_N14C_form__cexp_t_data_t* status_0,
   struct _fx_N14C_form__cexp_t_data_t* par_status_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   int_ km_idx_0,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   int fx_status = 0;
   _fx_N24C_gen_code__block_kind_t kind_0;
   if (ndims_0 == 1) {
      kind_0 = _fx_g26C_gen_code__BlockKind_Loop;
   }
   else {
      kind_0 = _fx_g28C_gen_code__BlockKind_LoopND;
   }
   FX_CALL(
      _fx_M10C_gen_codeFM14new_block_ctx_v5N24C_gen_code__block_kind_tR16Ast__for_flags_tR10Ast__loc_trLrRM11block_ctx_ti(
         &kind_0, for_flags_0, loc_0, block_stack_ref_0, km_idx_0, 0), _fx_cleanup);
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_0 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_0, 0), _fx_catch_0);
      FX_THROW(&v_0, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_0);
   }
   FX_CHECK_EXN(_fx_cleanup);
   _fx_N14C_form__cexp_t* v_1 = &bctx_0->data.bctx_status;
   _fx_free_N14C_form__cexp_t(v_1);
   FX_COPY_PTR(status_0, v_1);
   _fx_N14C_form__cexp_t* v_2 = &bctx_0->data.bctx_par_status;
   _fx_free_N14C_form__cexp_t(v_2);
   FX_COPY_PTR(par_status_0, v_2);

_fx_cleanup: ;
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM13pop_block_ctxv2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   int fx_status = 0;
   _fx_LrR23C_gen_code__block_ctx_t* block_stack_1 = &block_stack_ref_0->data;
   FX_COPY_PTR(*block_stack_1, &block_stack_0);
   if (block_stack_0 != 0) {
      _fx_LrR23C_gen_code__block_ctx_t* rest_0 = &block_stack_0->tl;
      _fx_free_LrR23C_gen_code__block_ctx_t(block_stack_1);
      FX_COPY_PTR(*rest_0, block_stack_1);
   }
   else {
      fx_exn_t v_0 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_0, 0), _fx_catch_0);
      FX_THROW(&v_0, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_0);
   }
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_N14C_form__cexp_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   int fx_status = 0;
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_0 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_0, 0), _fx_catch_0);
      FX_THROW(&v_0, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_0);
   }
   FX_CHECK_EXN(_fx_cleanup);
   bctx_0->data.bctx_label_used = bctx_0->data.bctx_label_used + 1;
   _fx_R9Ast__id_t v_1 = bctx_0->data.bctx_label;
   FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_1, loc_0, fx_result, 0), _fx_cleanup);

_fx_cleanup: ;
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_N14C_form__cexp_t_data_t* call_exp_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t v_0 = 0;
   _fx_LN14C_form__cexp_t v_1 = 0;
   _fx_N14C_form__cexp_t fx_call_e_0 = 0;
   _fx_N15C_form__cstmt_t v_2 = 0;
   int fx_status = 0;
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_3 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_3, 0), _fx_catch_0);
      FX_THROW(&v_3, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_3);
   }
   FX_CHECK_EXN(_fx_cleanup);
   bctx_0->data.bctx_label_used = bctx_0->data.bctx_label_used + 1;
   _fx_R9Ast__id_t v_4 = bctx_0->data.bctx_label;
   FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_4, loc_0, &v_0, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_0, 0, true, &v_1), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(call_exp_0, v_1, false, &v_1), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g19C_form__std_FX_CALL, v_1, _fx_g20C_gen_code__CTypVoid, loc_0, &fx_call_e_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(fx_call_e_0, &v_2), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_2, ccode_0, true, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (v_0) {
      _fx_free_N14C_form__cexp_t(&v_0);
   }
   if (v_1) {
      _fx_free_LN14C_form__cexp_t(&v_1);
   }
   if (fx_call_e_0) {
      _fx_free_N14C_form__cexp_t(&fx_call_e_0);
   }
   if (v_2) {
      _fx_free_N15C_form__cstmt_t(&v_2);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_R16Ast__val_flags_t* flags_0,
   struct _fx_Nt6option1N14C_form__cexp_t* e0_opt_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_R17C_form__ctprops_t v_0 = {0};
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t init_exp_0 = 0;
   _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1 = {0};
   _fx_Nt6option1N14C_form__cexp_t v_2 = {0};
   _fx_LN15C_form__cstmt_t v_3 = 0;
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_4 = {0};
   _fx_N14C_form__cexp_t i_exp_0 = 0;
   _fx_LN15C_form__cstmt_t prologue_0 = 0;
   _fx_LN15C_form__cstmt_t v_5 = 0;
   _fx_LN15C_form__cstmt_t v_6 = 0;
   _fx_LN15C_form__cstmt_t v_7 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, loc_0, &v_0, 0),
      _fx_cleanup);
   _fx_Ta2R9Ast__id_t* v_8 = &v_0.ctp_free;
   _fx_R9Ast__id_t freem_0 = v_8->t0;
   _fx_R9Ast__id_t freef_0 = v_8->t1;
   bool ctp_ptr_0 = v_0.ctp_ptr;
   bool res_0;
   FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&freem_0, &_fx_g9Ast__noid, &res_0, 0), _fx_cleanup);
   bool need_dtor_0;
   if (!res_0) {
      need_dtor_0 = true;
   }
   else {
      bool res_1;
      FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&freef_0, &_fx_g9Ast__noid, &res_1, 0), _fx_cleanup);
      need_dtor_0 = !res_1;
   }
   if (need_dtor_0) {
      FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
      if (block_stack_0 != 0) {
         FX_COPY_PTR(block_stack_0->hd, &bctx_0);
      }
      else {
         fx_exn_t v_9 = {0};
         fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_9, 0), _fx_catch_0);
         FX_THROW(&v_9, false, _fx_catch_0);

      _fx_catch_0: ;
         fx_free_exn(&v_9);
      }
      FX_CHECK_EXN(_fx_cleanup);
      if (ctp_ptr_0) {
         FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &init_exp_0, 0), _fx_cleanup);
      }
      else {
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, loc_0, &v_1);
         FX_CALL(
            _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(0, &v_1, &init_exp_0),
            _fx_cleanup);
      }
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(init_exp_0, &v_2);
      FX_COPY_PTR(bctx_0->data.bctx_prologue, &v_3);
      fx_str_t slit_1 = FX_MAKE_STR("");
      FX_CALL(
         _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
            i_0, ctyp_0, flags_0, &slit_1, &v_2, v_3, loc_0, &v_4, 0), _fx_cleanup);
      FX_COPY_PTR(v_4.t0, &i_exp_0);
      FX_COPY_PTR(v_4.t1, &prologue_0);
      _fx_LN15C_form__cstmt_t* v_10 = &bctx_0->data.bctx_prologue;
      _fx_free_LN15C_form__cstmt_t(v_10);
      FX_COPY_PTR(prologue_0, v_10);
      FX_COPY_PTR(bctx_0->data.bctx_cleanup, &v_5);
      FX_CALL(
         _fx_M11C_gen_typesFM13gen_free_codeLN15C_form__cstmt_t6N14C_form__cexp_tN14C_form__ctyp_tBBLN15C_form__cstmt_tR10Ast__loc_t(
            i_exp_0, ctyp_0, true, true, v_5, loc_0, &v_6, 0), _fx_cleanup);
      _fx_LN15C_form__cstmt_t* v_11 = &bctx_0->data.bctx_cleanup;
      _fx_free_LN15C_form__cstmt_t(v_11);
      FX_COPY_PTR(v_6, v_11);
      if (ctp_ptr_0 == true) {
         if (e0_opt_0->tag == 2) {
            _fx_N14C_form__cexp_t v_12 = e0_opt_0->u.Some;
            if (FX_REC_VARIANT_TAG(v_12) == 2) {
               if (v_12->u.CExpLit.t0.tag == 8) {
                  FX_COPY_PTR(ccode_0, &v_7); goto _fx_endmatch_0;
               }
            }
         }
      }
      if (e0_opt_0->tag == 2) {
         FX_CALL(
            _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
               e0_opt_0->u.Some, i_exp_0, ctyp_0, ccode_0, loc_0, &v_7, 0), _fx_catch_1);

      _fx_catch_1: ;
         goto _fx_endmatch_0;
      }
      FX_COPY_PTR(ccode_0, &v_7);

   _fx_endmatch_0: ;
      FX_CHECK_EXN(_fx_cleanup);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(i_exp_0, v_7, fx_result);
   }
   else {
      fx_str_t slit_2 = FX_MAKE_STR("");
      FX_CALL(
         _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
            i_0, ctyp_0, flags_0, &slit_2, e0_opt_0, ccode_0, loc_0, fx_result, 0), _fx_cleanup);
   }

_fx_cleanup: ;
   _fx_free_R17C_form__ctprops_t(&v_0);
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (init_exp_0) {
      _fx_free_N14C_form__cexp_t(&init_exp_0);
   }
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1);
   _fx_free_Nt6option1N14C_form__cexp_t(&v_2);
   if (v_3) {
      _fx_free_LN15C_form__cstmt_t(&v_3);
   }
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_4);
   if (i_exp_0) {
      _fx_free_N14C_form__cexp_t(&i_exp_0);
   }
   if (prologue_0) {
      _fx_free_LN15C_form__cstmt_t(&prologue_0);
   }
   if (v_5) {
      _fx_free_LN15C_form__cstmt_t(&v_5);
   }
   if (v_6) {
      _fx_free_LN15C_form__cstmt_t(&v_6);
   }
   if (v_7) {
      _fx_free_LN15C_form__cstmt_t(&v_7);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM17add_local_temprefT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_R9Ast__id_t* i_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_R16Ast__val_flags_t* flags_0,
   struct _fx_N14C_form__cexp_t_data_t* e0_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_R17C_form__ctprops_t v_0 = {0};
   _fx_T2N14C_form__cexp_tN14C_form__ctyp_t v_1 = {0};
   _fx_N14C_form__ctyp_t ctyp_ptr_0 = 0;
   _fx_N14C_form__cexp_t v_2 = 0;
   _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_3 = {0};
   _fx_N14C_form__cexp_t deref_i_exp_0 = 0;
   _fx_N14C_form__cexp_t v_4 = 0;
   _fx_N14C_form__cexp_t e_0 = 0;
   _fx_N14C_form__ctyp_t ctyp_1 = 0;
   _fx_Nt6option1N14C_form__cexp_t v_5 = {0};
   int fx_status = 0;
   _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t* i2e_0 = &i2e_ref_0->data;
   FX_CALL(_fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, loc_0, &v_0, 0),
      _fx_cleanup);
   bool ctp_ptr_0 = v_0.ctp_ptr;
   bool t_0;
   if (ctp_ptr_0) {
      t_0 = !flags_0->val_flag_mutable;
   }
   else {
      t_0 = false;
   }
   if (t_0) {
      _fx_make_T2N14C_form__cexp_tN14C_form__ctyp_t(e0_0, ctyp_0, &v_1);
   }
   else {
      FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(ctyp_0, &ctyp_ptr_0, 0), _fx_cleanup);
      FX_CALL(
         _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(i_0, ctyp_ptr_0, loc_0, &v_2,
            0), _fx_cleanup);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, loc_0, &v_3);
      FX_CALL(
         _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g20C_gen_code__COpDeref, v_2, &v_3, &deref_i_exp_0), _fx_cleanup);
      int_ idx_0;
      FX_CALL(
         _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_t(*i2e_0, i_0, &idx_0,
            0), _fx_cleanup);
      FX_CHKIDX(FX_CHKIDX1((*i2e_0)->u.t.t5, 0, idx_0), _fx_cleanup);
      _fx_N14C_form__cexp_t* v_6 =
         &FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, (*i2e_0)->u.t.t5, idx_0)->data;
      _fx_free_N14C_form__cexp_t(v_6);
      FX_COPY_PTR(deref_i_exp_0, v_6);
      FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e0_0, &v_4, 0), _fx_cleanup);
      _fx_make_T2N14C_form__cexp_tN14C_form__ctyp_t(v_4, ctyp_ptr_0, &v_1);
   }
   FX_COPY_PTR(v_1.t0, &e_0);
   FX_COPY_PTR(v_1.t1, &ctyp_1);
   _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(e_0, &v_5);
   fx_str_t slit_0 = FX_MAKE_STR("");
   FX_CALL(
      _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
         i_0, ctyp_1, flags_0, &slit_0, &v_5, ccode_0, loc_0, fx_result, 0), _fx_cleanup);

_fx_cleanup: ;
   _fx_free_R17C_form__ctprops_t(&v_0);
   _fx_free_T2N14C_form__cexp_tN14C_form__ctyp_t(&v_1);
   if (ctyp_ptr_0) {
      _fx_free_N14C_form__ctyp_t(&ctyp_ptr_0);
   }
   if (v_2) {
      _fx_free_N14C_form__cexp_t(&v_2);
   }
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_3);
   if (deref_i_exp_0) {
      _fx_free_N14C_form__cexp_t(&deref_i_exp_0);
   }
   if (v_4) {
      _fx_free_N14C_form__cexp_t(&v_4);
   }
   if (e_0) {
      _fx_free_N14C_form__cexp_t(&e_0);
   }
   if (ctyp_1) {
      _fx_free_N14C_form__ctyp_t(&ctyp_1);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&v_5);
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   fx_str_t* prefix_0,
   struct _fx_N14C_form__ctyp_t_data_t* ctyp_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   int_ km_idx_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_Nt6option1N14C_form__cexp_t v_0 = {0};
   int fx_status = 0;
   _fx_copy_Nt6option1N14C_form__cexp_t(&dstexp_r_0->data, &v_0);
   if (FX_REC_VARIANT_TAG(ctyp_0) == 8) {
      _fx_N14C_form__cexp_t v_1 = 0;
      FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_1, 0), _fx_catch_0);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_1, ccode_0, fx_result);

   _fx_catch_0: ;
      if (v_1) {
         _fx_free_N14C_form__cexp_t(&v_1);
      }
   }
   else if (v_0.tag == 2) {
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_0.u.Some, ccode_0, fx_result);
   }
   else {
      _fx_R16Ast__val_flags_t v_2 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_3 = {0};
      _fx_N14C_form__cexp_t i_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_1 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_4 = {0};
      _fx_R9Ast__id_t i_0;
      FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, prefix_0, &i_0, 0), _fx_catch_1);
      FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_2, 0), _fx_catch_1);
      FX_CALL(
         _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
            &i_0, ctyp_0, &v_2, &_fx_g18C_gen_code__None2_, ccode_0, loc_0, block_stack_ref_0, &v_3, 0), _fx_catch_1);
      FX_COPY_PTR(v_3.t0, &i_exp_0);
      FX_COPY_PTR(v_3.t1, &ccode_1);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(i_exp_0, &v_4);
      _fx_Nt6option1N14C_form__cexp_t* v_5 = &dstexp_r_0->data;
      _fx_free_Nt6option1N14C_form__cexp_t(v_5);
      _fx_copy_Nt6option1N14C_form__cexp_t(&v_4, v_5);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(i_exp_0, ccode_1, fx_result);

   _fx_catch_1: ;
      _fx_free_Nt6option1N14C_form__cexp_t(&v_4);
      if (ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&ccode_1);
      }
      if (i_exp_0) {
         _fx_free_N14C_form__cexp_t(&i_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_3);
      _fx_free_R16Ast__val_flags_t(&v_2);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&v_0);
   return fx_status;
}

static int _fx_M10C_gen_codeFM15make_break_stmtN15C_form__cstmt_t2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t v_0 = 0;
   _fx_LN14C_form__cexp_t v_1 = 0;
   _fx_N14C_form__cexp_t v_2 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M10C_gen_codeFM17check_inside_loopv3BR10Ast__loc_trLrRM11block_ctx_t(true, loc_0, block_stack_ref_0, 0),
      _fx_cleanup);
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_3 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_3, 0), _fx_catch_0);
      FX_THROW(&v_3, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_3);
   }
   FX_CHECK_EXN(_fx_cleanup);
   bctx_0->data.bctx_label_used = bctx_0->data.bctx_label_used + 1;
   _fx_R9Ast__id_t v_4 = bctx_0->data.bctx_label;
   FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_4, loc_0, &v_0, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_0, 0, true, &v_1), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g20C_form__std_FX_BREAK, v_1, _fx_g20C_gen_code__CTypVoid, loc_0, &v_2, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_2, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (v_0) {
      _fx_free_N14C_form__cexp_t(&v_0);
   }
   if (v_1) {
      _fx_free_LN14C_form__cexp_t(&v_1);
   }
   if (v_2) {
      _fx_free_N14C_form__cexp_t(&v_2);
   }
   return fx_status;
}

static int _fx_M10C_gen_codeFM18make_continue_stmtN15C_form__cstmt_t2R10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_N15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t v_0 = 0;
   _fx_LN14C_form__cexp_t v_1 = 0;
   _fx_N14C_form__cexp_t v_2 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M10C_gen_codeFM17check_inside_loopv3BR10Ast__loc_trLrRM11block_ctx_t(false, loc_0, block_stack_ref_0, 0),
      _fx_cleanup);
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_3 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_3, 0), _fx_catch_0);
      FX_THROW(&v_3, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_3);
   }
   FX_CHECK_EXN(_fx_cleanup);
   bctx_0->data.bctx_label_used = bctx_0->data.bctx_label_used + 1;
   _fx_R9Ast__id_t v_4 = bctx_0->data.bctx_label;
   FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_4, loc_0, &v_0, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_0, 0, true, &v_1), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g23C_form__std_FX_CONTINUE, v_1, _fx_g20C_gen_code__CTypVoid, loc_0, &v_2, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_2, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (v_0) {
      _fx_free_N14C_form__cexp_t(&v_0);
   }
   if (v_1) {
      _fx_free_LN14C_form__cexp_t(&v_1);
   }
   if (v_2) {
      _fx_free_N14C_form__cexp_t(&v_2);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_R9Ast__id_t* i_0,
   bool save_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_Nt6option1N14C_form__cexp_t v_0 = {0};
   _fx_N14C_form__cexp_t v_1 = 0;
   int fx_status = 0;
   _fx_Nt10Hashset__t1R9Ast__id_t* defined_syms_0 = &defined_syms_ref_0->data;
   _fx_LN15C_form__cstmt_t* fwd_fdecls_0 = &fwd_fdecls_ref_0->data;
   _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t* i2e_0 = &i2e_ref_0->data;
   _fx_Ta2i v_2;
   FX_CALL(_fx_M10C_gen_codeFM9find_idx_Ta2i2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_t(*i2e_0, i_0, &v_2, 0),
      _fx_cleanup);
   int_ j_0 = v_2.t1;
   if (j_0 >= 0) {
      FX_CHKIDX(FX_CHKIDX1((*i2e_0)->u.t.t5, 0, j_0), _fx_cleanup);
      FX_COPY_PTR(FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, (*i2e_0)->u.t.t5, j_0)->data, &v_1);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1, &v_0);
   }
   else {
      _fx_copy_Nt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_0);
   }
   if (v_0.tag == 2) {
      _fx_N14C_form__cexp_t e_0 = v_0.u.Some;
      bool res_0;
      if (save_0 == false) {
         res_0 = true; goto _fx_endmatch_0;
      }
      if (FX_REC_VARIANT_TAG(e_0) == 1) {
         res_0 = true; goto _fx_endmatch_0;
      }
      if (FX_REC_VARIANT_TAG(e_0) == 2) {
         res_0 = true; goto _fx_endmatch_0;
      }
      if (FX_REC_VARIANT_TAG(e_0) == 4) {
         _fx_T3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* vcase_0 = &e_0->u.CExpUnary;
         if (vcase_0->t0.tag == 5) {
            if (FX_REC_VARIANT_TAG(vcase_0->t1) == 1) {
               res_0 = true; goto _fx_endmatch_0;
            }
         }
      }
      res_0 = false;

   _fx_endmatch_0: ;
      FX_CHECK_EXN(_fx_catch_1);
      if (res_0) {
         _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(e_0, ccode_0, fx_result); goto _fx_endmatch_1;
      }
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_3 = {0};
      _fx_N14C_form__ctyp_t ctyp_0 = 0;
      _fx_R17K_form__kdefval_t v_4 = {0};
      _fx_R16Ast__val_flags_t kv_flags_0 = {0};
      _fx_T3BN14C_form__cexp_tN14C_form__ctyp_t v_5 = {0};
      _fx_N14C_form__cexp_t v_6 = 0;
      _fx_N14C_form__ctyp_t v_7 = 0;
      _fx_N14C_form__cexp_t e_1 = 0;
      _fx_N14C_form__ctyp_t ctyp_1 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_8 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_9 = {0};
      _fx_N14C_form__cexp_t i2_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_1 = 0;
      _fx_N14C_form__cexp_t v_10 = 0;
      FX_CALL(_fx_M6C_formFM12get_cexp_ctxT2N14C_form__ctyp_tR10Ast__loc_t1N14C_form__cexp_t(e_0, &v_3, 0), _fx_catch_0);
      FX_COPY_PTR(v_3.t0, &ctyp_0);
      FX_CALL(_fx_M6K_formFM8get_kvalRM9kdefval_t2R9Ast__id_tR10Ast__loc_t(i_0, loc_0, &v_4, 0), _fx_catch_0);
      _fx_copy_R16Ast__val_flags_t(&v_4.kv_flags, &kv_flags_0);
      _fx_R9Ast__id_t i2_0;
      FX_CALL(_fx_M6C_formFM7dup_idcR9Ast__id_t2iR9Ast__id_t(km_idx_0, i_0, &i2_0, 0), _fx_catch_0);
      if (kv_flags_0.val_flag_tempref) {
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_0, &v_6, 0), _fx_catch_0);
         FX_CALL(_fx_M6C_formFM10CTypRawPtrN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(0, ctyp_0, &v_7),
            _fx_catch_0);
         _fx_make_T3BN14C_form__cexp_tN14C_form__ctyp_t(true, v_6, v_7, &v_5);
      }
      else {
         _fx_make_T3BN14C_form__cexp_tN14C_form__ctyp_t(false, e_0, ctyp_0, &v_5);
      }
      bool add_deref_0 = v_5.t0;
      FX_COPY_PTR(v_5.t1, &e_1);
      FX_COPY_PTR(v_5.t2, &ctyp_1);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(e_1, &v_8);
      FX_CALL(
         _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
            &i2_0, ctyp_1, &kv_flags_0, &v_8, ccode_0, loc_0, block_stack_ref_0, &v_9, 0), _fx_catch_0);
      FX_COPY_PTR(v_9.t0, &i2_exp_0);
      FX_COPY_PTR(v_9.t1, &ccode_1);
      int_ idx_0;
      FX_CALL(
         _fx_M10C_gen_codeFM18find_idx_or_inserti2Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_t(*i2e_0, i_0, &idx_0,
            0), _fx_catch_0);
      FX_CHKIDX(FX_CHKIDX1((*i2e_0)->u.t.t5, 0, idx_0), _fx_catch_0);
      _fx_N14C_form__cexp_t* v_11 =
         &FX_PTR_1D(_fx_Rt20Hashmap__hashentry_t2R9Ast__id_tN14C_form__cexp_t, (*i2e_0)->u.t.t5, idx_0)->data;
      _fx_free_N14C_form__cexp_t(v_11);
      FX_COPY_PTR(i2_exp_0, v_11);
      if (add_deref_0) {
         FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(i2_exp_0, &v_10, 0), _fx_catch_0);
      }
      else {
         FX_COPY_PTR(i2_exp_0, &v_10);
      }
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_10, ccode_1, fx_result);

   _fx_catch_0: ;
      if (v_10) {
         _fx_free_N14C_form__cexp_t(&v_10);
      }
      if (ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&ccode_1);
      }
      if (i2_exp_0) {
         _fx_free_N14C_form__cexp_t(&i2_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_9);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_8);
      if (ctyp_1) {
         _fx_free_N14C_form__ctyp_t(&ctyp_1);
      }
      if (e_1) {
         _fx_free_N14C_form__cexp_t(&e_1);
      }
      if (v_7) {
         _fx_free_N14C_form__ctyp_t(&v_7);
      }
      if (v_6) {
         _fx_free_N14C_form__cexp_t(&v_6);
      }
      _fx_free_T3BN14C_form__cexp_tN14C_form__ctyp_t(&v_5);
      _fx_free_R16Ast__val_flags_t(&kv_flags_0);
      _fx_free_R17K_form__kdefval_t(&v_4);
      if (ctyp_0) {
         _fx_free_N14C_form__ctyp_t(&ctyp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_3);

   _fx_endmatch_1: ;
      FX_CHECK_EXN(_fx_catch_1);

   _fx_catch_1: ;
   }
   else {
      _fx_N14C_form__cexp_t e_2 = 0;
      _fx_N15C_form__cinfo_t v_12 = {0};
      _fx_N14C_form__cexp_t e_3 = 0;
      FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(i_0, loc_0, &e_2, 0), _fx_catch_4);
      FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(i_0, loc_0, &v_12, 0), _fx_catch_4);
      if (v_12.tag == 2) {
         _fx_N15C_form__cstmt_t v_13 = 0;
         _fx_LN15C_form__cstmt_t v_14 = 0;
         _fx_R17C_form__cdefval_t* v_15 = &v_12.u.CVal;
         _fx_R16Ast__val_flags_t* cv_flags_0 = &v_15->cv_flags;
         _fx_N14C_form__ctyp_t cv_typ_0 = v_15->cv_typ;
         bool res_1;
         FX_CALL(_fx_M6K_formFM13is_val_globalB1R16Ast__val_flags_t(cv_flags_0, &res_1, 0), _fx_catch_3);
         bool t_0;
         if (res_1) {
            t_0 = true;
         }
         else {
            t_0 = cv_flags_0->val_flag_ctor > 0;
         }
         if (t_0) {
            uint64_t __fold_result___0 = 14695981039346656037ULL;
            uint64_t h_0 = __fold_result___0 ^ ((uint64_t)i_0->m ^ 14695981039346656037ULL);
            __fold_result___0 = h_0 * 1099511628211ULL;
            uint64_t h_1 = __fold_result___0 ^ ((uint64_t)i_0->i ^ 14695981039346656037ULL);
            __fold_result___0 = h_1 * 1099511628211ULL;
            uint64_t h_2 = __fold_result___0 ^ ((uint64_t)i_0->j ^ 14695981039346656037ULL);
            __fold_result___0 = h_2 * 1099511628211ULL;
            _fx_Ta2i v_16;
            FX_CALL(
               _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*defined_syms_0, i_0,
                  __fold_result___0 & 9223372036854775807ULL, &v_16, 0), _fx_catch_3);
            if (!(v_16.t1 >= 0)) {
               uint64_t __fold_result___1 = 14695981039346656037ULL;
               uint64_t h_3 = __fold_result___1 ^ ((uint64_t)i_0->m ^ 14695981039346656037ULL);
               __fold_result___1 = h_3 * 1099511628211ULL;
               uint64_t h_4 = __fold_result___1 ^ ((uint64_t)i_0->i ^ 14695981039346656037ULL);
               __fold_result___1 = h_4 * 1099511628211ULL;
               uint64_t h_5 = __fold_result___1 ^ ((uint64_t)i_0->j ^ 14695981039346656037ULL);
               __fold_result___1 = h_5 * 1099511628211ULL;
               FX_CALL(
                  _fx_M10C_gen_codeFM4add_v3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(*defined_syms_0, i_0,
                     __fold_result___1 & 9223372036854775807ULL, 0), _fx_catch_3);
               FX_CALL(_fx_M6C_formFM14CDefForwardSymN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(i_0, loc_0, &v_13),
                  _fx_catch_3);
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_13, *fwd_fdecls_0, true, &v_14), _fx_catch_3);
               _fx_free_LN15C_form__cstmt_t(fwd_fdecls_0);
               FX_COPY_PTR(v_14, fwd_fdecls_0);
            }
         }
         if (FX_REC_VARIANT_TAG(cv_typ_0) == 17) {
            bool res_2;
            FX_CALL(
               _fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(cv_typ_0->u.CTypRawPtr.t1, cv_typ_0,
                  &res_2, 0), _fx_catch_3);
            if (res_2) {
               FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(e_2, &e_3, 0), _fx_catch_2);

            _fx_catch_2: ;
               goto _fx_endmatch_2;
            }
         }
         FX_COPY_PTR(e_2, &e_3);

      _fx_endmatch_2: ;
         FX_CHECK_EXN(_fx_catch_3);

      _fx_catch_3: ;
         if (v_14) {
            _fx_free_LN15C_form__cstmt_t(&v_14);
         }
         if (v_13) {
            _fx_free_N15C_form__cstmt_t(&v_13);
         }
      }
      else {
         FX_COPY_PTR(e_2, &e_3);
      }
      FX_CHECK_EXN(_fx_catch_4);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(e_3, ccode_0, fx_result);

   _fx_catch_4: ;
      if (e_3) {
         _fx_free_N14C_form__cexp_t(&e_3);
      }
      _fx_free_N15C_form__cinfo_t(&v_12);
      if (e_2) {
         _fx_free_N14C_form__cexp_t(&e_2);
      }
   }

_fx_cleanup: ;
   _fx_free_Nt6option1N14C_form__cexp_t(&v_0);
   if (v_1) {
      _fx_free_N14C_form__cexp_t(&v_1);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM18finalize_loop_bodyT2R9Ast__id_tN15C_form__cstmt_t4LN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_LN15C_form__cstmt_t_data_t* body_code_0,
   bool enable_break_continue_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_T2R9Ast__id_tN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t bctx_par_status_0 = 0;
   _fx_N14C_form__cexp_t bctx_status_0 = 0;
   _fx_LN15C_form__cstmt_t bctx_cleanup_0 = 0;
   _fx_LN15C_form__cstmt_t bctx_prologue_0 = 0;
   _fx_LN15C_form__cstmt_t __fold_result___0 = 0;
   _fx_LN15C_form__cstmt_t epilogue_0 = 0;
   _fx_T2R9Ast__id_tLN15C_form__cstmt_t v_0 = {0};
   _fx_LrR23C_gen_code__block_ctx_t block_stack_1 = 0;
   _fx_N14C_form__cexp_t parent_label_exp_0 = 0;
   _fx_N15C_form__cstmt_t v_1 = 0;
   _fx_LN15C_form__cstmt_t v_2 = 0;
   _fx_LN15C_form__cstmt_t epilogue_1 = 0;
   fx_exn_t v_3 = {0};
   _fx_LN15C_form__cstmt_t continue_code_0 = 0;
   _fx_N14C_form__cexp_t v_4 = 0;
   _fx_N15C_form__cstmt_t v_5 = 0;
   fx_exn_t v_6 = {0};
   _fx_T2R9Ast__id_tLN15C_form__cstmt_t v_7 = {0};
   _fx_N14C_form__cexp_t v_8 = 0;
   _fx_N15C_form__cstmt_t v_9 = 0;
   _fx_LN15C_form__cstmt_t v_10 = 0;
   _fx_N14C_form__cexp_t br_label_exp_0 = 0;
   _fx_LN14C_form__cexp_t v_11 = 0;
   _fx_N14C_form__cexp_t v_12 = 0;
   _fx_N15C_form__cstmt_t v_13 = 0;
   _fx_LN15C_form__cstmt_t v_14 = 0;
   fx_exn_t v_15 = {0};
   _fx_LN15C_form__cstmt_t break_code_0 = 0;
   _fx_LN15C_form__cstmt_t check_exn_code_0 = 0;
   _fx_LN14C_form__cexp_t v_16 = 0;
   _fx_N14C_form__cexp_t v_17 = 0;
   _fx_N15C_form__cstmt_t v_18 = 0;
   _fx_LN14C_form__cexp_t v_19 = 0;
   _fx_N14C_form__cexp_t v_20 = 0;
   _fx_N15C_form__cstmt_t v_21 = 0;
   _fx_LN15C_form__cstmt_t v_22 = 0;
   _fx_LN15C_form__cstmt_t v_23 = 0;
   _fx_LN15C_form__cstmt_t v_24 = 0;
   _fx_LN15C_form__cstmt_t epilogue_2 = 0;
   _fx_LN15C_form__cstmt_t v_25 = 0;
   _fx_LN15C_form__cstmt_t body_code_1 = 0;
   _fx_N15C_form__cstmt_t body_stmt_0 = 0;
   _fx_LrR23C_gen_code__block_ctx_t block_stack_2 = 0;
   int fx_status = 0;
   _fx_LrR23C_gen_code__block_ctx_t* block_stack_3 = &block_stack_ref_0->data;
   _fx_R10Ast__loc_t end_loc_0;
   FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(loc_0, &end_loc_0, 0), _fx_cleanup);
   FX_COPY_PTR(*block_stack_3, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_26 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_26, 0), _fx_catch_0);
      FX_THROW(&v_26, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_26);
   }
   FX_CHECK_EXN(_fx_cleanup);
   _fx_R23C_gen_code__block_ctx_t* v_27 = &bctx_0->data;
   int_ bctx_label_used_0 = v_27->bctx_label_used;
   _fx_R9Ast__id_t bctx_br_label_0 = v_27->bctx_br_label;
   _fx_R9Ast__id_t bctx_label_0 = v_27->bctx_label;
   _fx_R16Ast__for_flags_t bctx_for_flags_0 = v_27->bctx_for_flags;
   int_ bctx_continue_used_0 = v_27->bctx_continue_used;
   int_ bctx_break_used_0 = v_27->bctx_break_used;
   FX_COPY_PTR(v_27->bctx_par_status, &bctx_par_status_0);
   FX_COPY_PTR(v_27->bctx_status, &bctx_status_0);
   FX_COPY_PTR(v_27->bctx_cleanup, &bctx_cleanup_0);
   FX_COPY_PTR(v_27->bctx_prologue, &bctx_prologue_0);
   _fx_N24C_gen_code__block_kind_t bctx_kind_0 = v_27->bctx_kind;
   int tag_0 = bctx_kind_0.tag;
   bool res_0;
   if (tag_0 == 5) {
      res_0 = true;
   }
   else if (tag_0 == 6) {
      res_0 = true;
   }
   else {
      res_0 = false;
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (res_0) {
      goto _fx_endmatch_0;
   }
   fx_exn_t v_28 = {0};
   fx_str_t slit_1 = FX_MAKE_STR("cgen: the current context is not a loop");
   FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_1, &v_28, 0), _fx_catch_1);
   FX_THROW(&v_28, false, _fx_catch_1);

_fx_catch_1: ;
   fx_free_exn(&v_28);

_fx_endmatch_0: ;
   FX_CHECK_EXN(_fx_cleanup);
   _fx_LN15C_form__cstmt_t lst_0 = bctx_cleanup_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LN15C_form__cstmt_t r_0 = 0;
      _fx_N15C_form__cstmt_t a_0 = lst_0->hd;
      FX_COPY_PTR(__fold_result___0, &r_0);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(a_0, r_0, false, &r_0), _fx_catch_2);
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
      FX_COPY_PTR(r_0, &__fold_result___0);

   _fx_catch_2: ;
      if (r_0) {
         _fx_free_LN15C_form__cstmt_t(&r_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, &epilogue_0);
   bool is_parallel_0 = bctx_for_flags_0.for_flag_parallel;
   if (bctx_label_used_0 + bctx_break_used_0 + bctx_continue_used_0 == 0) {
      _fx_make_T2R9Ast__id_tLN15C_form__cstmt_t(&_fx_g9Ast__noid, epilogue_0, &v_0);
   }
   else {
      FX_COPY_PTR(*block_stack_3, &block_stack_1);
      if (block_stack_1 != 0) {
         _fx_LrR23C_gen_code__block_ctx_t v_29 = block_stack_1->tl;
         if (v_29 != 0) {
            _fx_rR23C_gen_code__block_ctx_t parent_0 = v_29->hd;
            parent_0->data.bctx_label_used = parent_0->data.bctx_label_used + 1;
            _fx_R9Ast__id_t v_30 = parent_0->data.bctx_label;
            FX_CALL(
               _fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_30, &end_loc_0, &parent_label_exp_0, 0),
               _fx_catch_3);

         _fx_catch_3: ;
            goto _fx_endmatch_1;
         }
      }
      fx_exn_t v_31 = {0};
      fx_str_t slit_2 = FX_MAKE_STR("cgen internal err: there is no parent block!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&end_loc_0, &slit_2, &v_31, 0), _fx_catch_4);
      FX_THROW(&v_31, false, _fx_catch_4);

   _fx_catch_4: ;
      fx_free_exn(&v_31);

   _fx_endmatch_1: ;
      FX_CHECK_EXN(_fx_cleanup);
      FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&bctx_label_0, &end_loc_0, &v_1),
         _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1, 0, true, &v_2), _fx_cleanup);
      if (epilogue_0 == 0) {
         FX_COPY_PTR(v_2, &epilogue_1);
      }
      else if (v_2 == 0) {
         FX_COPY_PTR(epilogue_0, &epilogue_1);
      }
      else {
         _fx_LN15C_form__cstmt_t v_32 = 0;
         _fx_LN15C_form__cstmt_t lstend_0 = 0;
         _fx_LN15C_form__cstmt_t lst_1 = epilogue_0;
         for (; lst_1; lst_1 = lst_1->tl) {
            _fx_N15C_form__cstmt_t x_0 = lst_1->hd;
            _fx_LN15C_form__cstmt_t node_0 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_0, 0, false, &node_0), _fx_catch_5);
            FX_LIST_APPEND(v_32, lstend_0, node_0);

         _fx_catch_5: ;
            FX_CHECK_EXN(_fx_catch_6);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_32, v_2, &epilogue_1, 0);

      _fx_catch_6: ;
         if (v_32) {
            _fx_free_LN15C_form__cstmt_t(&v_32);
         }
      }
      FX_CHECK_EXN(_fx_cleanup);
      bool t_0;
      if (!enable_break_continue_0) {
         t_0 = bctx_continue_used_0 + bctx_break_used_0 != 0;
      }
      else {
         t_0 = false;
      }
      if (t_0) {
         fx_str_t slit_3 = FX_MAKE_STR("cgen: cannot use break/continue inside comprehensions");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_3, &v_3, 0), _fx_cleanup);
         FX_THROW(&v_3, false, _fx_cleanup);
      }
      if (bctx_continue_used_0 != 0) {
         if (!is_parallel_0) {
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g29C_form__std_FX_CHECK_CONTINUE, 0, _fx_g20C_gen_code__CTypVoid, &end_loc_0, &v_4, 0), _fx_cleanup);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_4, &v_5), _fx_cleanup);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_5, 0, true, &continue_code_0), _fx_cleanup);
         }
         else {
            fx_str_t slit_4 = FX_MAKE_STR("cgen: \'continue\' may not be used inside parallel for");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_4, &v_6, 0), _fx_cleanup);
            FX_THROW(&v_6, false, _fx_cleanup);
         }
      }
      if (bctx_break_used_0 == 0) {
         _fx_make_T2R9Ast__id_tLN15C_form__cstmt_t(&_fx_g9Ast__noid, 0, &v_7);
      }
      else {
         bool res_1;
         FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&bctx_br_label_0, &_fx_g9Ast__noid, &res_1, 0), _fx_cleanup);
         if (res_1) {
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g26C_form__std_FX_CHECK_BREAK, 0, _fx_g20C_gen_code__CTypVoid, &end_loc_0, &v_8, 0), _fx_cleanup);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_8, &v_9), _fx_cleanup);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_9, 0, true, &v_10), _fx_cleanup);
            _fx_make_T2R9Ast__id_tLN15C_form__cstmt_t(&_fx_g9Ast__noid, v_10, &v_7);
         }
         else if (!is_parallel_0) {
            FX_CALL(
               _fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&bctx_br_label_0, &end_loc_0,
                  &br_label_exp_0, 0), _fx_cleanup);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(br_label_exp_0, 0, true, &v_11), _fx_cleanup);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g29C_form__std_FX_CHECK_BREAK_ND, v_11, _fx_g20C_gen_code__CTypVoid, &end_loc_0, &v_12, 0), _fx_cleanup);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_12, &v_13), _fx_cleanup);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_13, 0, true, &v_14), _fx_cleanup);
            _fx_make_T2R9Ast__id_tLN15C_form__cstmt_t(&bctx_br_label_0, v_14, &v_7);
         }
         else {
            fx_str_t slit_5 = FX_MAKE_STR("cgen: \'break\' may not be used inside parallel for");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_5, &v_15, 0), _fx_cleanup);
            FX_THROW(&v_15, false, _fx_cleanup);
         }
      }
      _fx_R9Ast__id_t br_label_0 = v_7.t0;
      FX_COPY_PTR(v_7.t1, &break_code_0);
      if (!is_parallel_0) {
         FX_CALL(_fx_cons_LN14C_form__cexp_t(parent_label_exp_0, 0, true, &v_16), _fx_cleanup);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g24C_form__std_FX_CHECK_EXN, v_16, _fx_g20C_gen_code__CTypVoid, &end_loc_0, &v_17, 0), _fx_cleanup);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_17, &v_18), _fx_cleanup);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_18, 0, true, &check_exn_code_0), _fx_cleanup);
      }
      else {
         _fx_R9Ast__id_t v_33;
         fx_str_t slit_6 = FX_MAKE_STR("FX_CHECK_EXN_PARALLEL");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_6, &v_33, 0), _fx_cleanup);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(bctx_par_status_0, 0, true, &v_19), _fx_cleanup);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(bctx_status_0, v_19, false, &v_19), _fx_cleanup);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_33, v_19,
               _fx_g20C_gen_code__CTypVoid, &end_loc_0, &v_20, 0), _fx_cleanup);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_20, &v_21), _fx_cleanup);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_21, 0, true, &check_exn_code_0), _fx_cleanup);
      }
      if (continue_code_0 == 0) {
         FX_COPY_PTR(epilogue_1, &v_22);
      }
      else if (epilogue_1 == 0) {
         FX_COPY_PTR(continue_code_0, &v_22);
      }
      else {
         _fx_LN15C_form__cstmt_t v_34 = 0;
         _fx_LN15C_form__cstmt_t lstend_1 = 0;
         _fx_LN15C_form__cstmt_t lst_2 = continue_code_0;
         for (; lst_2; lst_2 = lst_2->tl) {
            _fx_N15C_form__cstmt_t x_1 = lst_2->hd;
            _fx_LN15C_form__cstmt_t node_1 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_1, 0, false, &node_1), _fx_catch_7);
            FX_LIST_APPEND(v_34, lstend_1, node_1);

         _fx_catch_7: ;
            FX_CHECK_EXN(_fx_catch_8);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_34, epilogue_1, &v_22, 0);

      _fx_catch_8: ;
         if (v_34) {
            _fx_free_LN15C_form__cstmt_t(&v_34);
         }
      }
      FX_CHECK_EXN(_fx_cleanup);
      if (break_code_0 == 0) {
         FX_COPY_PTR(v_22, &v_23);
      }
      else if (v_22 == 0) {
         FX_COPY_PTR(break_code_0, &v_23);
      }
      else {
         _fx_LN15C_form__cstmt_t v_35 = 0;
         _fx_LN15C_form__cstmt_t lstend_2 = 0;
         _fx_LN15C_form__cstmt_t lst_3 = break_code_0;
         for (; lst_3; lst_3 = lst_3->tl) {
            _fx_N15C_form__cstmt_t x_2 = lst_3->hd;
            _fx_LN15C_form__cstmt_t node_2 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_2, 0, false, &node_2), _fx_catch_9);
            FX_LIST_APPEND(v_35, lstend_2, node_2);

         _fx_catch_9: ;
            FX_CHECK_EXN(_fx_catch_10);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_35, v_22, &v_23, 0);

      _fx_catch_10: ;
         if (v_35) {
            _fx_free_LN15C_form__cstmt_t(&v_35);
         }
      }
      FX_CHECK_EXN(_fx_cleanup);
      if (check_exn_code_0 == 0) {
         FX_COPY_PTR(v_23, &v_24);
      }
      else if (v_23 == 0) {
         FX_COPY_PTR(check_exn_code_0, &v_24);
      }
      else {
         _fx_LN15C_form__cstmt_t v_36 = 0;
         _fx_LN15C_form__cstmt_t lstend_3 = 0;
         _fx_LN15C_form__cstmt_t lst_4 = check_exn_code_0;
         for (; lst_4; lst_4 = lst_4->tl) {
            _fx_N15C_form__cstmt_t x_3 = lst_4->hd;
            _fx_LN15C_form__cstmt_t node_3 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_3, 0, false, &node_3), _fx_catch_11);
            FX_LIST_APPEND(v_36, lstend_3, node_3);

         _fx_catch_11: ;
            FX_CHECK_EXN(_fx_catch_12);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_36, v_23, &v_24, 0);

      _fx_catch_12: ;
         if (v_36) {
            _fx_free_LN15C_form__cstmt_t(&v_36);
         }
      }
      FX_CHECK_EXN(_fx_cleanup);
      _fx_make_T2R9Ast__id_tLN15C_form__cstmt_t(&br_label_0, v_24, &v_0);
   }
   _fx_R9Ast__id_t br_label_1 = v_0.t0;
   FX_COPY_PTR(v_0.t1, &epilogue_2);
   if (body_code_0 == 0) {
      FX_COPY_PTR(bctx_prologue_0, &v_25);
   }
   else if (bctx_prologue_0 == 0) {
      FX_COPY_PTR(body_code_0, &v_25);
   }
   else {
      _fx_LN15C_form__cstmt_t v_37 = 0;
      _fx_LN15C_form__cstmt_t lstend_4 = 0;
      _fx_LN15C_form__cstmt_t lst_5 = body_code_0;
      for (; lst_5; lst_5 = lst_5->tl) {
         _fx_N15C_form__cstmt_t x_4 = lst_5->hd;
         _fx_LN15C_form__cstmt_t node_4 = 0;
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_4, 0, false, &node_4), _fx_catch_13);
         FX_LIST_APPEND(v_37, lstend_4, node_4);

      _fx_catch_13: ;
         FX_CHECK_EXN(_fx_catch_14);
      }
      _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_37, bctx_prologue_0, &v_25, 0);

   _fx_catch_14: ;
      if (v_37) {
         _fx_free_LN15C_form__cstmt_t(&v_37);
      }
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (epilogue_2 == 0) {
      FX_COPY_PTR(v_25, &body_code_1);
   }
   else if (v_25 == 0) {
      FX_COPY_PTR(epilogue_2, &body_code_1);
   }
   else {
      _fx_LN15C_form__cstmt_t v_38 = 0;
      _fx_LN15C_form__cstmt_t lstend_5 = 0;
      _fx_LN15C_form__cstmt_t lst_6 = epilogue_2;
      for (; lst_6; lst_6 = lst_6->tl) {
         _fx_N15C_form__cstmt_t x_5 = lst_6->hd;
         _fx_LN15C_form__cstmt_t node_5 = 0;
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_5, 0, false, &node_5), _fx_catch_15);
         FX_LIST_APPEND(v_38, lstend_5, node_5);

      _fx_catch_15: ;
         FX_CHECK_EXN(_fx_catch_16);
      }
      _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_38, v_25, &body_code_1, 0);

   _fx_catch_16: ;
      if (v_38) {
         _fx_free_LN15C_form__cstmt_t(&v_38);
      }
   }
   FX_CHECK_EXN(_fx_cleanup);
   FX_CALL(_fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(body_code_1, loc_0, &body_stmt_0, 0),
      _fx_cleanup);
   FX_COPY_PTR(*block_stack_3, &block_stack_2);
   if (block_stack_2 != 0) {
      _fx_LrR23C_gen_code__block_ctx_t* rest_0 = &block_stack_2->tl;
      _fx_free_LrR23C_gen_code__block_ctx_t(block_stack_3);
      FX_COPY_PTR(*rest_0, block_stack_3);
   }
   else {
      fx_exn_t v_39 = {0};
      fx_str_t slit_7 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&end_loc_0, &slit_7, &v_39, 0), _fx_catch_17);
      FX_THROW(&v_39, false, _fx_catch_17);

   _fx_catch_17: ;
      fx_free_exn(&v_39);
   }
   FX_CHECK_EXN(_fx_cleanup);
   _fx_make_T2R9Ast__id_tN15C_form__cstmt_t(&br_label_1, body_stmt_0, fx_result);

_fx_cleanup: ;
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (bctx_par_status_0) {
      _fx_free_N14C_form__cexp_t(&bctx_par_status_0);
   }
   if (bctx_status_0) {
      _fx_free_N14C_form__cexp_t(&bctx_status_0);
   }
   if (bctx_cleanup_0) {
      _fx_free_LN15C_form__cstmt_t(&bctx_cleanup_0);
   }
   if (bctx_prologue_0) {
      _fx_free_LN15C_form__cstmt_t(&bctx_prologue_0);
   }
   if (__fold_result___0) {
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
   }
   if (epilogue_0) {
      _fx_free_LN15C_form__cstmt_t(&epilogue_0);
   }
   _fx_free_T2R9Ast__id_tLN15C_form__cstmt_t(&v_0);
   if (block_stack_1) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_1);
   }
   if (parent_label_exp_0) {
      _fx_free_N14C_form__cexp_t(&parent_label_exp_0);
   }
   if (v_1) {
      _fx_free_N15C_form__cstmt_t(&v_1);
   }
   if (v_2) {
      _fx_free_LN15C_form__cstmt_t(&v_2);
   }
   if (epilogue_1) {
      _fx_free_LN15C_form__cstmt_t(&epilogue_1);
   }
   fx_free_exn(&v_3);
   if (continue_code_0) {
      _fx_free_LN15C_form__cstmt_t(&continue_code_0);
   }
   if (v_4) {
      _fx_free_N14C_form__cexp_t(&v_4);
   }
   if (v_5) {
      _fx_free_N15C_form__cstmt_t(&v_5);
   }
   fx_free_exn(&v_6);
   _fx_free_T2R9Ast__id_tLN15C_form__cstmt_t(&v_7);
   if (v_8) {
      _fx_free_N14C_form__cexp_t(&v_8);
   }
   if (v_9) {
      _fx_free_N15C_form__cstmt_t(&v_9);
   }
   if (v_10) {
      _fx_free_LN15C_form__cstmt_t(&v_10);
   }
   if (br_label_exp_0) {
      _fx_free_N14C_form__cexp_t(&br_label_exp_0);
   }
   if (v_11) {
      _fx_free_LN14C_form__cexp_t(&v_11);
   }
   if (v_12) {
      _fx_free_N14C_form__cexp_t(&v_12);
   }
   if (v_13) {
      _fx_free_N15C_form__cstmt_t(&v_13);
   }
   if (v_14) {
      _fx_free_LN15C_form__cstmt_t(&v_14);
   }
   fx_free_exn(&v_15);
   if (break_code_0) {
      _fx_free_LN15C_form__cstmt_t(&break_code_0);
   }
   if (check_exn_code_0) {
      _fx_free_LN15C_form__cstmt_t(&check_exn_code_0);
   }
   if (v_16) {
      _fx_free_LN14C_form__cexp_t(&v_16);
   }
   if (v_17) {
      _fx_free_N14C_form__cexp_t(&v_17);
   }
   if (v_18) {
      _fx_free_N15C_form__cstmt_t(&v_18);
   }
   if (v_19) {
      _fx_free_LN14C_form__cexp_t(&v_19);
   }
   if (v_20) {
      _fx_free_N14C_form__cexp_t(&v_20);
   }
   if (v_21) {
      _fx_free_N15C_form__cstmt_t(&v_21);
   }
   if (v_22) {
      _fx_free_LN15C_form__cstmt_t(&v_22);
   }
   if (v_23) {
      _fx_free_LN15C_form__cstmt_t(&v_23);
   }
   if (v_24) {
      _fx_free_LN15C_form__cstmt_t(&v_24);
   }
   if (epilogue_2) {
      _fx_free_LN15C_form__cstmt_t(&epilogue_2);
   }
   if (v_25) {
      _fx_free_LN15C_form__cstmt_t(&v_25);
   }
   if (body_code_1) {
      _fx_free_LN15C_form__cstmt_t(&body_code_1);
   }
   if (body_stmt_0) {
      _fx_free_N15C_form__cstmt_t(&body_stmt_0);
   }
   if (block_stack_2) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_2);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* a_0,
   bool save_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t_cldata_t*)
         fx_fv;
   int_* km_idx_0 = &cv_0->t4;
   int tag_0 = a_0->tag;
   if (tag_0 == 2) {
      _fx_N14K_form__klit_t* l_0 = &a_0->u.AtomLit;
      int tag_1 = l_0->tag;
      if (tag_1 == 5) {
         _fx_N14C_form__cexp_t v_0 = 0;
         _fx_LN14C_form__cexp_t v_1 = 0;
         _fx_N14C_form__cexp_t e0_0 = 0;
         _fx_R16Ast__val_flags_t v_2 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_3 = {0};
         FX_CALL(_fx_M6C_formFM12make_lit_expN14C_form__cexp_t2N14K_form__klit_tR10Ast__loc_t(l_0, loc_0, &v_0, 0),
            _fx_catch_0);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_0, 0, true, &v_1), _fx_catch_0);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g23C_form__std_FX_MAKE_STR, v_1, _fx_g22C_gen_code__CTypString, loc_0, &e0_0, 0), _fx_catch_0);
         _fx_R9Ast__id_t v_4;
         fx_str_t slit_0 = FX_MAKE_STR("slit");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(*km_idx_0, &slit_0, &v_4, 0), _fx_catch_0);
         FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_2, 0), _fx_catch_0);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(e0_0, &v_3);
         fx_str_t slit_1 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_4, _fx_g22C_gen_code__CTypString, &v_2, &slit_1, &v_3, ccode_0, loc_0, fx_result, 0), _fx_catch_0);

      _fx_catch_0: ;
         _fx_free_Nt6option1N14C_form__cexp_t(&v_3);
         _fx_free_R16Ast__val_flags_t(&v_2);
         if (e0_0) {
            _fx_free_N14C_form__cexp_t(&e0_0);
         }
         if (v_1) {
            _fx_free_LN14C_form__cexp_t(&v_1);
         }
         if (v_0) {
            _fx_free_N14C_form__cexp_t(&v_0);
         }
      }
      else if (tag_1 == 8) {
         _fx_N14K_form__ktyp_t v_5 = 0;
         _fx_N14K_form__ktyp_t ktyp_0 = l_0->u.KLitNil;
         FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_0, loc_0, &v_5, 0),
            _fx_catch_5);
         int tag_2 = FX_REC_VARIANT_TAG(v_5);
         bool res_0;
         if (tag_2 == 19) {
            res_0 = true;
         }
         else if (tag_2 == 11) {
            res_0 = true;
         }
         else if (tag_2 == 12) {
            res_0 = true;
         }
         else {
            res_0 = false;
         }
         FX_CHECK_EXN(_fx_catch_5);
         if (res_0) {
            _fx_N14C_form__cexp_t v_6 = 0;
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_6, 0), _fx_catch_1);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_6, ccode_0, fx_result);

         _fx_catch_1: ;
            if (v_6) {
               _fx_free_N14C_form__cexp_t(&v_6);
            }
            goto _fx_endmatch_0;
         }
         if (tag_2 == 18) {
            _fx_N14C_form__ctyp_t elem_ctyp_0 = 0;
            _fx_Ta3N14C_form__cexp_t v_7 = {0};
            _fx_N14C_form__cexp_t elemsize_exp_0 = 0;
            _fx_N14C_form__cexp_t free_f_exp_0 = 0;
            _fx_N14C_form__cexp_t copy_f_exp_0 = 0;
            _fx_N14C_form__ctyp_t v_8 = 0;
            _fx_R16Ast__val_flags_t v_9 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_10 = {0};
            _fx_N14C_form__cexp_t vec_exp_0 = 0;
            _fx_LN15C_form__cstmt_t ccode_1 = 0;
            _fx_N14C_form__cexp_t v_11 = 0;
            _fx_LN14C_form__cexp_t v_12 = 0;
            _fx_N14C_form__cexp_t call_make_empty_0 = 0;
            _fx_N15C_form__cstmt_t v_13 = 0;
            _fx_LN15C_form__cstmt_t v_14 = 0;
            FX_CALL(
               _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(v_5->u.KTypVector, loc_0,
                  &elem_ctyp_0, 0), _fx_catch_2);
            FX_CALL(
               _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_0,
                  loc_0, &v_7, 0), _fx_catch_2);
            FX_COPY_PTR(v_7.t0, &elemsize_exp_0);
            FX_COPY_PTR(v_7.t1, &free_f_exp_0);
            FX_COPY_PTR(v_7.t2, &copy_f_exp_0);
            _fx_R9Ast__id_t v_15;
            fx_str_t slit_2 = FX_MAKE_STR("zvec");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(*km_idx_0, &slit_2, &v_15, 0), _fx_catch_2);
            FX_CALL(_fx_M6C_formFM10CTypVectorN14C_form__ctyp_t1N14C_form__ctyp_t(elem_ctyp_0, &v_8), _fx_catch_2);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_9, 0), _fx_catch_2);
            fx_str_t slit_3 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_15, v_8, &v_9, &slit_3, &_fx_g18C_gen_code__None2_, ccode_0, loc_0, &v_10, 0), _fx_catch_2);
            FX_COPY_PTR(v_10.t0, &vec_exp_0);
            FX_COPY_PTR(v_10.t1, &ccode_1);
            _fx_R9Ast__id_t v_16;
            fx_str_t slit_4 = FX_MAKE_STR("fx_rrb_make_empty");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_4, &v_16, 0), _fx_catch_2);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(vec_exp_0, &v_11, 0), _fx_catch_2);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_11, 0, true, &v_12), _fx_catch_2);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_0, v_12, false, &v_12), _fx_catch_2);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_0, v_12, false, &v_12), _fx_catch_2);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(elemsize_exp_0, v_12, false, &v_12), _fx_catch_2);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_16,
                  v_12, _fx_g20C_gen_code__CTypVoid, loc_0, &call_make_empty_0, 0), _fx_catch_2);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_make_empty_0, &v_13), _fx_catch_2);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_13, ccode_1, true, &v_14), _fx_catch_2);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(vec_exp_0, v_14, fx_result);

         _fx_catch_2: ;
            if (v_14) {
               _fx_free_LN15C_form__cstmt_t(&v_14);
            }
            if (v_13) {
               _fx_free_N15C_form__cstmt_t(&v_13);
            }
            if (call_make_empty_0) {
               _fx_free_N14C_form__cexp_t(&call_make_empty_0);
            }
            if (v_12) {
               _fx_free_LN14C_form__cexp_t(&v_12);
            }
            if (v_11) {
               _fx_free_N14C_form__cexp_t(&v_11);
            }
            if (ccode_1) {
               _fx_free_LN15C_form__cstmt_t(&ccode_1);
            }
            if (vec_exp_0) {
               _fx_free_N14C_form__cexp_t(&vec_exp_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_10);
            _fx_free_R16Ast__val_flags_t(&v_9);
            if (v_8) {
               _fx_free_N14C_form__ctyp_t(&v_8);
            }
            if (copy_f_exp_0) {
               _fx_free_N14C_form__cexp_t(&copy_f_exp_0);
            }
            if (free_f_exp_0) {
               _fx_free_N14C_form__cexp_t(&free_f_exp_0);
            }
            if (elemsize_exp_0) {
               _fx_free_N14C_form__cexp_t(&elemsize_exp_0);
            }
            _fx_free_Ta3N14C_form__cexp_t(&v_7);
            if (elem_ctyp_0) {
               _fx_free_N14C_form__ctyp_t(&elem_ctyp_0);
            }
            goto _fx_endmatch_0;
         }
         if (tag_2 == 17) {
            _fx_N14C_form__ctyp_t elem_ctyp_1 = 0;
            _fx_Ta3N14C_form__cexp_t v_17 = {0};
            _fx_N14C_form__cexp_t elemsize_exp_1 = 0;
            _fx_N14C_form__cexp_t free_f_exp_1 = 0;
            _fx_N14C_form__cexp_t copy_f_exp_1 = 0;
            _fx_N14C_form__ctyp_t v_18 = 0;
            _fx_R16Ast__val_flags_t v_19 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_20 = {0};
            _fx_N14C_form__cexp_t arr_exp_0 = 0;
            _fx_LN15C_form__cstmt_t ccode_2 = 0;
            _fx_N14C_form__cexp_t v_21 = 0;
            _fx_N14C_form__cexp_t v_22 = 0;
            _fx_N14C_form__cexp_t v_23 = 0;
            _fx_N14C_form__cexp_t v_24 = 0;
            _fx_LN14C_form__cexp_t v_25 = 0;
            _fx_N14C_form__cexp_t call_make_empty_1 = 0;
            _fx_N15C_form__cstmt_t v_26 = 0;
            _fx_LN15C_form__cstmt_t v_27 = 0;
            _fx_T2iN14K_form__ktyp_t* vcase_0 = &v_5->u.KTypArray;
            int_ ndims_0 = vcase_0->t0;
            FX_CALL(
               _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(vcase_0->t1, loc_0, &elem_ctyp_1,
                  0), _fx_catch_3);
            FX_CALL(
               _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_1,
                  loc_0, &v_17, 0), _fx_catch_3);
            FX_COPY_PTR(v_17.t0, &elemsize_exp_1);
            FX_COPY_PTR(v_17.t1, &free_f_exp_1);
            FX_COPY_PTR(v_17.t2, &copy_f_exp_1);
            _fx_R9Ast__id_t v_28;
            fx_str_t slit_5 = FX_MAKE_STR("zarr");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(*km_idx_0, &slit_5, &v_28, 0), _fx_catch_3);
            FX_CALL(_fx_M6C_formFM9CTypArrayN14C_form__ctyp_t2iN14C_form__ctyp_t(ndims_0, elem_ctyp_1, &v_18), _fx_catch_3);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_19, 0), _fx_catch_3);
            fx_str_t slit_6 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_28, v_18, &v_19, &slit_6, &_fx_g18C_gen_code__None2_, ccode_0, loc_0, &v_20, 0), _fx_catch_3);
            FX_COPY_PTR(v_20.t0, &arr_exp_0);
            FX_COPY_PTR(v_20.t1, &ccode_2);
            _fx_R9Ast__id_t v_29;
            fx_str_t slit_7 = FX_MAKE_STR("fx_make_arr");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_7, &v_29, 0), _fx_catch_3);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(ndims_0, loc_0, &v_21, 0), _fx_catch_3);
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_22, 0), _fx_catch_3);
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_23, 0), _fx_catch_3);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_0, &v_24, 0), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_24, 0, true, &v_25), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_23, v_25, false, &v_25), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_1, v_25, false, &v_25), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_1, v_25, false, &v_25), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(elemsize_exp_1, v_25, false, &v_25), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_22, v_25, false, &v_25), _fx_catch_3);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_21, v_25, false, &v_25), _fx_catch_3);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_29,
                  v_25, _fx_g20C_gen_code__CTypVoid, loc_0, &call_make_empty_1, 0), _fx_catch_3);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_make_empty_1, &v_26), _fx_catch_3);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_26, ccode_2, true, &v_27), _fx_catch_3);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(arr_exp_0, v_27, fx_result);

         _fx_catch_3: ;
            if (v_27) {
               _fx_free_LN15C_form__cstmt_t(&v_27);
            }
            if (v_26) {
               _fx_free_N15C_form__cstmt_t(&v_26);
            }
            if (call_make_empty_1) {
               _fx_free_N14C_form__cexp_t(&call_make_empty_1);
            }
            if (v_25) {
               _fx_free_LN14C_form__cexp_t(&v_25);
            }
            if (v_24) {
               _fx_free_N14C_form__cexp_t(&v_24);
            }
            if (v_23) {
               _fx_free_N14C_form__cexp_t(&v_23);
            }
            if (v_22) {
               _fx_free_N14C_form__cexp_t(&v_22);
            }
            if (v_21) {
               _fx_free_N14C_form__cexp_t(&v_21);
            }
            if (ccode_2) {
               _fx_free_LN15C_form__cstmt_t(&ccode_2);
            }
            if (arr_exp_0) {
               _fx_free_N14C_form__cexp_t(&arr_exp_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_20);
            _fx_free_R16Ast__val_flags_t(&v_19);
            if (v_18) {
               _fx_free_N14C_form__ctyp_t(&v_18);
            }
            if (copy_f_exp_1) {
               _fx_free_N14C_form__cexp_t(&copy_f_exp_1);
            }
            if (free_f_exp_1) {
               _fx_free_N14C_form__cexp_t(&free_f_exp_1);
            }
            if (elemsize_exp_1) {
               _fx_free_N14C_form__cexp_t(&elemsize_exp_1);
            }
            _fx_free_Ta3N14C_form__cexp_t(&v_17);
            if (elem_ctyp_1) {
               _fx_free_N14C_form__ctyp_t(&elem_ctyp_1);
            }
            goto _fx_endmatch_0;
         }
         fx_str_t v_30 = {0};
         fx_str_t v_31 = {0};
         fx_exn_t v_32 = {0};
         FX_CALL(_fx_M6K_formFM6stringS1N14K_form__ktyp_t(ktyp_0, &v_30, 0), _fx_catch_4);
         fx_str_t slit_8 = FX_MAKE_STR("cgen: unsupported type \'");
         fx_str_t slit_9 = FX_MAKE_STR("\' of \'[]\' literal");
         {
            const fx_str_t strs_0[] = { slit_8, v_30, slit_9 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_0, 3, &v_31), _fx_catch_4);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_31, &v_32, 0), _fx_catch_4);
         FX_THROW(&v_32, false, _fx_catch_4);

      _fx_catch_4: ;
         fx_free_exn(&v_32);
         FX_FREE_STR(&v_31);
         FX_FREE_STR(&v_30);

      _fx_endmatch_0: ;
         FX_CHECK_EXN(_fx_catch_5);

      _fx_catch_5: ;
         if (v_5) {
            _fx_free_N14K_form__ktyp_t(&v_5);
         }
      }
      else {
         _fx_N14C_form__cexp_t e_0 = 0;
         FX_CALL(_fx_M6C_formFM12make_lit_expN14C_form__cexp_t2N14K_form__klit_tR10Ast__loc_t(l_0, loc_0, &e_0, 0),
            _fx_catch_6);
         _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(e_0, ccode_0, fx_result);

      _fx_catch_6: ;
         if (e_0) {
            _fx_free_N14C_form__cexp_t(&e_0);
         }
      }
      FX_CHECK_EXN(_fx_catch_7);

   _fx_catch_7: ;
   }
   else if (tag_0 == 1) {
      FX_CALL(
         _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
            &a_0->u.AtomId, save_0, ccode_0, loc_0, cv_0->t0, cv_0->t1, cv_0->t2, cv_0->t3, *km_idx_0, fx_result, 0),
         _fx_catch_8);

   _fx_catch_8: ;
   }
   else {
      FX_FAST_THROW(FX_EXN_NoMatchError, _fx_cleanup);
   }

_fx_cleanup: ;
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t* fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t_cldata_t,
      _fx_free_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t,
      _fx_M10C_gen_codeFM10atom2cexp_T2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

static int
   _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_N14K_form__atom_t* a_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t atom2cexp__0 = {0};
   int fx_status = 0;
   _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t*)
         fx_fv;
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      cv_0->t0, cv_0->t1, cv_0->t2, cv_0->t3, cv_0->t4, &atom2cexp__0);
   FX_CALL(atom2cexp__0.fp(a_0, false, ccode_0, loc_0, fx_result, atom2cexp__0.fcv), _fx_cleanup);

_fx_cleanup: ;
   FX_FREE_FP(&atom2cexp__0);
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti*
      fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t,
      _fx_free_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti,
      _fx_M10C_gen_codeFM9atom2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

static int
   _fx_M10C_gen_codeFM18make_make_arr_callLN15C_form__cstmt_t7N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
   struct _fx_N14C_form__cexp_t_data_t* arr_exp_0,
   struct _fx_LN14C_form__cexp_t_data_t* shape_0,
   struct _fx_LN14C_form__cexp_t_data_t* data_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode0_0,
   struct _fx_N14C_form__cexp_t_data_t* lbl_0,
   struct _fx_R10Ast__loc_t* loc_0,
   int_ km_idx_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t arr_ctyp_0 = 0;
   _fx_LN19C_form__ctyp_attr_t v_0 = 0;
   _fx_N14C_form__ctyp_t shape_ctyp_0 = 0;
   _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1 = {0};
   _fx_N14C_form__cexp_t shape_arr_0 = 0;
   _fx_R16Ast__val_flags_t v_2 = {0};
   _fx_Nt6option1N14C_form__cexp_t v_3 = {0};
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_4 = {0};
   _fx_N14C_form__cexp_t shape_exp_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_0 = 0;
   _fx_N14C_form__ctyp_t elem_ctyp_0 = 0;
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_5 = {0};
   _fx_N14C_form__cexp_t data_exp_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_1 = 0;
   _fx_Ta3N14C_form__cexp_t v_6 = {0};
   _fx_N14C_form__cexp_t sizeof_elem_exp_0 = 0;
   _fx_N14C_form__cexp_t free_f_exp_0 = 0;
   _fx_N14C_form__cexp_t copy_f_exp_0 = 0;
   _fx_N14C_form__cexp_t v_7 = 0;
   _fx_N14C_form__cexp_t v_8 = 0;
   _fx_LN14C_form__cexp_t v_9 = 0;
   _fx_N14C_form__cexp_t call_mkarr_0 = 0;
   _fx_LN14C_form__cexp_t v_10 = 0;
   _fx_N14C_form__cexp_t fx_call_e_0 = 0;
   _fx_N15C_form__cstmt_t v_11 = 0;
   _fx_LN15C_form__cstmt_t ccode_2 = 0;
   _fx_N15C_form__cstmt_t v_12 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(arr_exp_0, &arr_ctyp_0, 0), _fx_cleanup);
   int_ dims_0 = _fx_M10C_gen_codeFM6lengthi1LN14C_form__cexp_t(shape_0, 0);
   FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_0), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_0, _fx_g19C_gen_code__CTypInt,
         &shape_ctyp_0), _fx_cleanup);
   _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(shape_ctyp_0, loc_0, &v_1);
   FX_CALL(
      _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(shape_0, &v_1, &shape_arr_0),
      _fx_cleanup);
   _fx_R9Ast__id_t v_13;
   fx_str_t slit_0 = FX_MAKE_STR("shape");
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_0, &v_13, 0), _fx_cleanup);
   FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_2, 0), _fx_cleanup);
   _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(shape_arr_0, &v_3);
   fx_str_t slit_1 = FX_MAKE_STR("");
   FX_CALL(
      _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
         &v_13, shape_ctyp_0, &v_2, &slit_1, &v_3, 0, loc_0, &v_4, 0), _fx_cleanup);
   FX_COPY_PTR(v_4.t0, &shape_exp_0);
   FX_COPY_PTR(v_4.t1, &ccode_0);
   if (FX_REC_VARIANT_TAG(arr_ctyp_0) == 19) {
      fx_str_t v_14 = {0};
      fx_str_t v_15 = {0};
      fx_str_t v_16 = {0};
      fx_exn_t v_17 = {0};
      _fx_T2iN14C_form__ctyp_t* vcase_0 = &arr_ctyp_0->u.CTypArray;
      int_ dims0_0 = vcase_0->t0;
      if (dims0_0 != dims_0) {
         FX_CALL(_fx_F6stringS1i(dims_0, &v_14, 0), _fx_catch_0);
         FX_CALL(_fx_F6stringS1i(dims0_0, &v_15, 0), _fx_catch_0);
         fx_str_t slit_2 = FX_MAKE_STR("cgen: incorrect number of shape elements (actual: ");
         fx_str_t slit_3 = FX_MAKE_STR(", expected: ");
         fx_str_t slit_4 = FX_MAKE_STR(")");
         {
            const fx_str_t strs_0[] = { slit_2, v_14, slit_3, v_15, slit_4 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_0, 5, &v_16), _fx_catch_0);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_16, &v_17, 0), _fx_catch_0);
         FX_THROW(&v_17, false, _fx_catch_0);
      }
      FX_COPY_PTR(vcase_0->t1, &elem_ctyp_0);

   _fx_catch_0: ;
      fx_free_exn(&v_17);
      FX_FREE_STR(&v_16);
      FX_FREE_STR(&v_15);
      FX_FREE_STR(&v_14);
   }
   else {
      fx_exn_t v_18 = {0};
      fx_str_t slit_5 = FX_MAKE_STR("cgen: invalid output type of array construction expression");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_5, &v_18, 0), _fx_catch_1);
      FX_THROW(&v_18, false, _fx_catch_1);

   _fx_catch_1: ;
      fx_free_exn(&v_18);
   }
   FX_CHECK_EXN(_fx_cleanup);
   _fx_R9Ast__id_t v_19;
   fx_str_t slit_6 = FX_MAKE_STR("data");
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_6, &v_19, 0), _fx_cleanup);
   if (data_0 == 0) {
      _fx_N14C_form__cexp_t v_20 = 0;
      FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_20, 0), _fx_catch_2);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_20, ccode_0, &v_5);

   _fx_catch_2: ;
      if (v_20) {
         _fx_free_N14C_form__cexp_t(&v_20);
      }
   }
   else {
      _fx_LN19C_form__ctyp_attr_t v_21 = 0;
      _fx_N14C_form__ctyp_t arr_ctyp_1 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_22 = {0};
      _fx_N14C_form__cexp_t arr_data_exp_0 = 0;
      _fx_R16Ast__val_flags_t v_23 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_24 = {0};
      FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_21), _fx_catch_3);
      FX_CALL(
         _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_21, elem_ctyp_0, &arr_ctyp_1),
         _fx_catch_3);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(arr_ctyp_1, loc_0, &v_22);
      FX_CALL(
         _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(data_0, &v_22,
            &arr_data_exp_0), _fx_catch_3);
      FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_23, 0), _fx_catch_3);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(arr_data_exp_0, &v_24);
      fx_str_t slit_7 = FX_MAKE_STR("");
      FX_CALL(
         _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
            &v_19, arr_ctyp_1, &v_23, &slit_7, &v_24, ccode_0, loc_0, &v_5, 0), _fx_catch_3);

   _fx_catch_3: ;
      _fx_free_Nt6option1N14C_form__cexp_t(&v_24);
      _fx_free_R16Ast__val_flags_t(&v_23);
      if (arr_data_exp_0) {
         _fx_free_N14C_form__cexp_t(&arr_data_exp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_22);
      if (arr_ctyp_1) {
         _fx_free_N14C_form__ctyp_t(&arr_ctyp_1);
      }
      FX_FREE_LIST_SIMPLE(&v_21);
   }
   FX_CHECK_EXN(_fx_cleanup);
   FX_COPY_PTR(v_5.t0, &data_exp_0);
   FX_COPY_PTR(v_5.t1, &ccode_1);
   FX_CALL(
      _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_0, loc_0, &v_6,
         0), _fx_cleanup);
   FX_COPY_PTR(v_6.t0, &sizeof_elem_exp_0);
   FX_COPY_PTR(v_6.t1, &free_f_exp_0);
   FX_COPY_PTR(v_6.t2, &copy_f_exp_0);
   FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(dims_0, loc_0, &v_7, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_0, &v_8, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_8, 0, true, &v_9), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(data_exp_0, v_9, false, &v_9), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_0, v_9, false, &v_9), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_0, v_9, false, &v_9), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(sizeof_elem_exp_0, v_9, false, &v_9), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(shape_exp_0, v_9, false, &v_9), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_7, v_9, false, &v_9), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g23C_form__std_fx_make_arr, v_9, _fx_g20C_gen_code__CTypCInt, loc_0, &call_mkarr_0, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_0, 0, true, &v_10), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(call_mkarr_0, v_10, false, &v_10), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g19C_form__std_FX_CALL, v_10, _fx_g20C_gen_code__CTypVoid, loc_0, &fx_call_e_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(fx_call_e_0, &v_11), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_11, ccode_1, true, &ccode_2), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(ccode_2, loc_0, &v_12, 0),
      _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_12, ccode0_0, true, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (arr_ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&arr_ctyp_0);
   }
   FX_FREE_LIST_SIMPLE(&v_0);
   if (shape_ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&shape_ctyp_0);
   }
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1);
   if (shape_arr_0) {
      _fx_free_N14C_form__cexp_t(&shape_arr_0);
   }
   _fx_free_R16Ast__val_flags_t(&v_2);
   _fx_free_Nt6option1N14C_form__cexp_t(&v_3);
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_4);
   if (shape_exp_0) {
      _fx_free_N14C_form__cexp_t(&shape_exp_0);
   }
   if (ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&ccode_0);
   }
   if (elem_ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&elem_ctyp_0);
   }
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_5);
   if (data_exp_0) {
      _fx_free_N14C_form__cexp_t(&data_exp_0);
   }
   if (ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&ccode_1);
   }
   _fx_free_Ta3N14C_form__cexp_t(&v_6);
   if (sizeof_elem_exp_0) {
      _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_0);
   }
   if (free_f_exp_0) {
      _fx_free_N14C_form__cexp_t(&free_f_exp_0);
   }
   if (copy_f_exp_0) {
      _fx_free_N14C_form__cexp_t(&copy_f_exp_0);
   }
   if (v_7) {
      _fx_free_N14C_form__cexp_t(&v_7);
   }
   if (v_8) {
      _fx_free_N14C_form__cexp_t(&v_8);
   }
   if (v_9) {
      _fx_free_LN14C_form__cexp_t(&v_9);
   }
   if (call_mkarr_0) {
      _fx_free_N14C_form__cexp_t(&call_mkarr_0);
   }
   if (v_10) {
      _fx_free_LN14C_form__cexp_t(&v_10);
   }
   if (fx_call_e_0) {
      _fx_free_N14C_form__cexp_t(&fx_call_e_0);
   }
   if (v_11) {
      _fx_free_N15C_form__cstmt_t(&v_11);
   }
   if (ccode_2) {
      _fx_free_LN15C_form__cstmt_t(&ccode_2);
   }
   if (v_12) {
      _fx_free_N15C_form__cstmt_t(&v_12);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM18make_make_vec_callLN15C_form__cstmt_t6N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
   struct _fx_N14C_form__cexp_t_data_t* vec_exp_0,
   struct _fx_LN14C_form__cexp_t_data_t* data_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode0_0,
   struct _fx_N14C_form__cexp_t_data_t* lbl_0,
   struct _fx_R10Ast__loc_t* loc_0,
   int_ km_idx_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t vec_ctyp_0 = 0;
   _fx_N14C_form__ctyp_t elem_ctyp_0 = 0;
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_0 = {0};
   _fx_N14C_form__cexp_t v_1 = 0;
   _fx_N14C_form__cexp_t data_exp_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_0 = 0;
   _fx_N14C_form__cexp_t nelems_exp_0 = 0;
   _fx_Ta3N14C_form__cexp_t v_2 = {0};
   _fx_N14C_form__cexp_t sizeof_elem_exp_0 = 0;
   _fx_N14C_form__cexp_t free_f_exp_0 = 0;
   _fx_N14C_form__cexp_t copy_f_exp_0 = 0;
   _fx_N14C_form__cexp_t v_3 = 0;
   _fx_LN14C_form__cexp_t v_4 = 0;
   _fx_N14C_form__cexp_t call_mkvec_0 = 0;
   _fx_LN14C_form__cexp_t v_5 = 0;
   _fx_N14C_form__cexp_t fx_call_e_0 = 0;
   _fx_N15C_form__cstmt_t v_6 = 0;
   _fx_LN15C_form__cstmt_t ccode_1 = 0;
   _fx_N15C_form__cstmt_t v_7 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(vec_exp_0, &vec_ctyp_0, 0), _fx_cleanup);
   if (FX_REC_VARIANT_TAG(vec_ctyp_0) == 20) {
      FX_COPY_PTR(vec_ctyp_0->u.CTypVector, &elem_ctyp_0);
   }
   else {
      fx_exn_t v_8 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: invalid output type of vector construction expression");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_8, 0), _fx_catch_0);
      FX_THROW(&v_8, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_8);
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (data_0 != 0) {
      _fx_R9Ast__id_t v_9;
      fx_str_t slit_1 = FX_MAKE_STR("data");
      FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_1, &v_9, 0), _fx_cleanup);
      if (data_0 == 0) {
         _fx_N14C_form__cexp_t v_10 = 0;
         FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_10, 0), _fx_catch_1);
         _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_10, 0, &v_0);

      _fx_catch_1: ;
         if (v_10) {
            _fx_free_N14C_form__cexp_t(&v_10);
         }
      }
      else {
         _fx_LN19C_form__ctyp_attr_t v_11 = 0;
         _fx_N14C_form__ctyp_t arr_ctyp_0 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_12 = {0};
         _fx_N14C_form__cexp_t arr_data_exp_0 = 0;
         _fx_R16Ast__val_flags_t v_13 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_14 = {0};
         FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_11), _fx_catch_2);
         FX_CALL(
            _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_11, elem_ctyp_0,
               &arr_ctyp_0), _fx_catch_2);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(arr_ctyp_0, loc_0, &v_12);
         FX_CALL(
            _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(data_0, &v_12,
               &arr_data_exp_0), _fx_catch_2);
         FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_13, 0), _fx_catch_2);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(arr_data_exp_0, &v_14);
         fx_str_t slit_2 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_9, arr_ctyp_0, &v_13, &slit_2, &v_14, 0, loc_0, &v_0, 0), _fx_catch_2);

      _fx_catch_2: ;
         _fx_free_Nt6option1N14C_form__cexp_t(&v_14);
         _fx_free_R16Ast__val_flags_t(&v_13);
         if (arr_data_exp_0) {
            _fx_free_N14C_form__cexp_t(&arr_data_exp_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_12);
         if (arr_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&arr_ctyp_0);
         }
         FX_FREE_LIST_SIMPLE(&v_11);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   else {
      FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(loc_0, &v_1, 0), _fx_cleanup);
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_1, 0, &v_0);
   }
   FX_COPY_PTR(v_0.t0, &data_exp_0);
   FX_COPY_PTR(v_0.t1, &ccode_0);
   int_ v_15 = _fx_M10C_gen_codeFM6lengthi1LN14C_form__cexp_t(data_0, 0);
   FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(v_15, loc_0, &nelems_exp_0, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_0, loc_0, &v_2,
         0), _fx_cleanup);
   FX_COPY_PTR(v_2.t0, &sizeof_elem_exp_0);
   FX_COPY_PTR(v_2.t1, &free_f_exp_0);
   FX_COPY_PTR(v_2.t2, &copy_f_exp_0);
   FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(vec_exp_0, &v_3, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_3, 0, true, &v_4), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(data_exp_0, v_4, false, &v_4), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_0, v_4, false, &v_4), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_0, v_4, false, &v_4), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(sizeof_elem_exp_0, v_4, false, &v_4), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(nelems_exp_0, v_4, false, &v_4), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g23C_form__std_fx_make_vec, v_4, _fx_g20C_gen_code__CTypCInt, loc_0, &call_mkvec_0, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_0, 0, true, &v_5), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(call_mkvec_0, v_5, false, &v_5), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g19C_form__std_FX_CALL, v_5, _fx_g20C_gen_code__CTypVoid, loc_0, &fx_call_e_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(fx_call_e_0, &v_6), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_6, ccode_0, true, &ccode_1), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(ccode_1, loc_0, &v_7, 0),
      _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_7, ccode0_0, true, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (vec_ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&vec_ctyp_0);
   }
   if (elem_ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&elem_ctyp_0);
   }
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_0);
   if (v_1) {
      _fx_free_N14C_form__cexp_t(&v_1);
   }
   if (data_exp_0) {
      _fx_free_N14C_form__cexp_t(&data_exp_0);
   }
   if (ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&ccode_0);
   }
   if (nelems_exp_0) {
      _fx_free_N14C_form__cexp_t(&nelems_exp_0);
   }
   _fx_free_Ta3N14C_form__cexp_t(&v_2);
   if (sizeof_elem_exp_0) {
      _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_0);
   }
   if (free_f_exp_0) {
      _fx_free_N14C_form__cexp_t(&free_f_exp_0);
   }
   if (copy_f_exp_0) {
      _fx_free_N14C_form__cexp_t(&copy_f_exp_0);
   }
   if (v_3) {
      _fx_free_N14C_form__cexp_t(&v_3);
   }
   if (v_4) {
      _fx_free_LN14C_form__cexp_t(&v_4);
   }
   if (call_mkvec_0) {
      _fx_free_N14C_form__cexp_t(&call_mkvec_0);
   }
   if (v_5) {
      _fx_free_LN14C_form__cexp_t(&v_5);
   }
   if (fx_call_e_0) {
      _fx_free_N14C_form__cexp_t(&fx_call_e_0);
   }
   if (v_6) {
      _fx_free_N15C_form__cstmt_t(&v_6);
   }
   if (ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&ccode_1);
   }
   if (v_7) {
      _fx_free_N15C_form__cstmt_t(&v_7);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM14make_cons_callLN15C_form__cstmt_t7N14C_form__cexp_tN14C_form__cexp_tBN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_N14C_form__cexp_t_data_t* hd_exp_0,
   struct _fx_N14C_form__cexp_t_data_t* tl_exp_0,
   bool addref_tl_0,
   struct _fx_N14C_form__cexp_t_data_t* lst_exp_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t ctyp_0 = 0;
   _fx_N14C_form__ctyp_t ctyp_1 = 0;
   _fx_R17C_form__ctprops_t v_0 = {0};
   _fx_N14C_form__cexp_t hd_exp_1 = 0;
   _fx_N14C_form__cexp_t v_1 = 0;
   _fx_N14C_form__cexp_t v_2 = 0;
   _fx_LN14C_form__cexp_t v_3 = 0;
   _fx_N14C_form__cexp_t call_cons_0 = 0;
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t v_4 = 0;
   _fx_LN14C_form__cexp_t v_5 = 0;
   _fx_N14C_form__cexp_t fx_call_e_0 = 0;
   _fx_N15C_form__cstmt_t v_6 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(lst_exp_0, &ctyp_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(hd_exp_0, &ctyp_1, 0), _fx_cleanup);
   FX_CALL(_fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_1, loc_0, &v_0, 0),
      _fx_cleanup);
   bool ctp_pass_by_ref_0 = v_0.ctp_pass_by_ref;
   if (ctp_pass_by_ref_0) {
      FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(hd_exp_0, &hd_exp_1, 0), _fx_cleanup);
   }
   else {
      FX_COPY_PTR(hd_exp_0, &hd_exp_1);
   }
   _fx_R9Ast__id_t lcon_0;
   FX_CALL(_fx_M11C_gen_typesFM15get_constructorR9Ast__id_t3N14C_form__ctyp_tBR10Ast__loc_t(ctyp_0, true, loc_0, &lcon_0, 0),
      _fx_cleanup);
   FX_CALL(_fx_M6C_formFM13make_bool_expN14C_form__cexp_t2BR10Ast__loc_t(addref_tl_0, loc_0, &v_1, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(lst_exp_0, &v_2, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_2, 0, true, &v_3), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1, v_3, false, &v_3), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(tl_exp_0, v_3, false, &v_3), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(hd_exp_1, v_3, false, &v_3), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&lcon_0, v_3,
         _fx_g20C_gen_code__CTypCInt, loc_0, &call_cons_0, 0), _fx_cleanup);
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_7 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_7, 0), _fx_catch_0);
      FX_THROW(&v_7, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_7);
   }
   FX_CHECK_EXN(_fx_cleanup);
   bctx_0->data.bctx_label_used = bctx_0->data.bctx_label_used + 1;
   _fx_R9Ast__id_t v_8 = bctx_0->data.bctx_label;
   FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_8, loc_0, &v_4, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_4, 0, true, &v_5), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(call_cons_0, v_5, false, &v_5), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g19C_form__std_FX_CALL, v_5, _fx_g20C_gen_code__CTypVoid, loc_0, &fx_call_e_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(fx_call_e_0, &v_6), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_6, ccode_0, true, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&ctyp_0);
   }
   if (ctyp_1) {
      _fx_free_N14C_form__ctyp_t(&ctyp_1);
   }
   _fx_free_R17C_form__ctprops_t(&v_0);
   if (hd_exp_1) {
      _fx_free_N14C_form__cexp_t(&hd_exp_1);
   }
   if (v_1) {
      _fx_free_N14C_form__cexp_t(&v_1);
   }
   if (v_2) {
      _fx_free_N14C_form__cexp_t(&v_2);
   }
   if (v_3) {
      _fx_free_LN14C_form__cexp_t(&v_3);
   }
   if (call_cons_0) {
      _fx_free_N14C_form__cexp_t(&call_cons_0);
   }
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (v_4) {
      _fx_free_N14C_form__cexp_t(&v_4);
   }
   if (v_5) {
      _fx_free_LN14C_form__cexp_t(&v_5);
   }
   if (fx_call_e_0) {
      _fx_free_N14C_form__cexp_t(&fx_call_e_0);
   }
   if (v_6) {
      _fx_free_N15C_form__cstmt_t(&v_6);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM15make_mkref_callLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
   struct _fx_N14C_form__cexp_t_data_t* arg_exp_0,
   struct _fx_N14C_form__cexp_t_data_t* r_exp_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_N14C_form__ctyp_t ctyp_0 = 0;
   _fx_N14C_form__ctyp_t ctyp_1 = 0;
   _fx_R17C_form__ctprops_t v_0 = {0};
   _fx_N14C_form__cexp_t arg_exp_1 = 0;
   _fx_N14C_form__cexp_t v_1 = 0;
   _fx_LN14C_form__cexp_t v_2 = 0;
   _fx_N14C_form__cexp_t call_mkref_0 = 0;
   _fx_LrR23C_gen_code__block_ctx_t block_stack_0 = 0;
   _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
   _fx_N14C_form__cexp_t v_3 = 0;
   _fx_LN14C_form__cexp_t v_4 = 0;
   _fx_N14C_form__cexp_t fx_call_e_0 = 0;
   _fx_N15C_form__cstmt_t v_5 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(r_exp_0, &ctyp_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(arg_exp_0, &ctyp_1, 0), _fx_cleanup);
   FX_CALL(_fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_1, loc_0, &v_0, 0),
      _fx_cleanup);
   bool ctp_pass_by_ref_0 = v_0.ctp_pass_by_ref;
   if (ctp_pass_by_ref_0) {
      FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arg_exp_0, &arg_exp_1, 0), _fx_cleanup);
   }
   else {
      FX_COPY_PTR(arg_exp_0, &arg_exp_1);
   }
   _fx_R9Ast__id_t rcon_0;
   FX_CALL(_fx_M11C_gen_typesFM15get_constructorR9Ast__id_t3N14C_form__ctyp_tBR10Ast__loc_t(ctyp_0, true, loc_0, &rcon_0, 0),
      _fx_cleanup);
   FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(r_exp_0, &v_1, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1, 0, true, &v_2), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(arg_exp_1, v_2, false, &v_2), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&rcon_0, v_2,
         _fx_g20C_gen_code__CTypCInt, loc_0, &call_mkref_0, 0), _fx_cleanup);
   FX_COPY_PTR(block_stack_ref_0->data, &block_stack_0);
   if (block_stack_0 != 0) {
      FX_COPY_PTR(block_stack_0->hd, &bctx_0);
   }
   else {
      fx_exn_t v_6 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty block stack!");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &slit_0, &v_6, 0), _fx_catch_0);
      FX_THROW(&v_6, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_6);
   }
   FX_CHECK_EXN(_fx_cleanup);
   bctx_0->data.bctx_label_used = bctx_0->data.bctx_label_used + 1;
   _fx_R9Ast__id_t v_7 = bctx_0->data.bctx_label;
   FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_7, loc_0, &v_3, 0), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(v_3, 0, true, &v_4), _fx_cleanup);
   FX_CALL(_fx_cons_LN14C_form__cexp_t(call_mkref_0, v_4, false, &v_4), _fx_cleanup);
   FX_CALL(
      _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
         &_fx_g19C_form__std_FX_CALL, v_4, _fx_g20C_gen_code__CTypVoid, loc_0, &fx_call_e_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(fx_call_e_0, &v_5), _fx_cleanup);
   FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_5, ccode_0, true, fx_result), _fx_cleanup);

_fx_cleanup: ;
   if (ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&ctyp_0);
   }
   if (ctyp_1) {
      _fx_free_N14C_form__ctyp_t(&ctyp_1);
   }
   _fx_free_R17C_form__ctprops_t(&v_0);
   if (arg_exp_1) {
      _fx_free_N14C_form__cexp_t(&arg_exp_1);
   }
   if (v_1) {
      _fx_free_N14C_form__cexp_t(&v_1);
   }
   if (v_2) {
      _fx_free_LN14C_form__cexp_t(&v_2);
   }
   if (call_mkref_0) {
      _fx_free_N14C_form__cexp_t(&call_mkref_0);
   }
   if (block_stack_0) {
      _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_0);
   }
   if (bctx_0) {
      _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
   }
   if (v_3) {
      _fx_free_N14C_form__cexp_t(&v_3);
   }
   if (v_4) {
      _fx_free_LN14C_form__cexp_t(&v_4);
   }
   if (fx_call_e_0) {
      _fx_free_N14C_form__cexp_t(&fx_call_e_0);
   }
   if (v_5) {
      _fx_free_N15C_form__cstmt_t(&v_5);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM19add_size_post_checkLN15C_form__cstmt_t5LN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
   struct _fx_LN14C_form__cexp_t_data_t* check_list_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_N14C_form__cexp_t_data_t* lbl_0,
   struct _fx_R10Ast__loc_t* loc_0,
   int_ km_idx_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (check_list_0 != 0) {
      _fx_N14C_form__cexp_t __fold_result___0 = 0;
      _fx_LN14C_form__cexp_t rest_0 = 0;
      _fx_N14C_form__cexp_t sum_checks_0 = 0;
      _fx_R16Ast__val_flags_t v_0 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_1 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_2 = {0};
      _fx_N14C_form__cexp_t sum_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_1 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t bool_ctx_0 = {0};
      _fx_N14C_form__cexp_t v_3 = 0;
      _fx_N14C_form__cexp_t v_4 = 0;
      _fx_N14C_form__cexp_t v_5 = 0;
      _fx_N14C_form__cexp_t v_6 = 0;
      _fx_N14C_form__cexp_t check_exp_0 = 0;
      _fx_LN14C_form__cexp_t v_7 = 0;
      _fx_N14C_form__cexp_t check_call_0 = 0;
      _fx_N15C_form__cstmt_t v_8 = 0;
      int_ n_0 = _fx_M10C_gen_codeFM6lengthi1LN14C_form__cexp_t(check_list_0, 0);
      FX_COPY_PTR(check_list_0->hd, &__fold_result___0);
      FX_COPY_PTR(check_list_0->tl, &rest_0);
      _fx_LN14C_form__cexp_t lst_0 = rest_0;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_N14C_form__cexp_t sum_checks_1 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_9 = {0};
         _fx_N14C_form__cexp_t v_10 = 0;
         _fx_N14C_form__cexp_t check_i_0 = lst_0->hd;
         FX_COPY_PTR(__fold_result___0, &sum_checks_1);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypCInt, loc_0, &v_9);
         FX_CALL(
            _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g18C_gen_code__COpAdd, sum_checks_1, check_i_0, &v_9, &v_10), _fx_catch_0);
         _fx_free_N14C_form__cexp_t(&__fold_result___0);
         FX_COPY_PTR(v_10, &__fold_result___0);

      _fx_catch_0: ;
         if (v_10) {
            _fx_free_N14C_form__cexp_t(&v_10);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_9);
         if (sum_checks_1) {
            _fx_free_N14C_form__cexp_t(&sum_checks_1);
         }
         FX_CHECK_EXN(_fx_catch_1);
      }
      FX_COPY_PTR(__fold_result___0, &sum_checks_0);
      _fx_R9Ast__id_t sum_id_0;
      fx_str_t slit_0 = FX_MAKE_STR("s");
      FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_0, &sum_id_0, 0), _fx_catch_1);
      FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_0, 0), _fx_catch_1);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(sum_checks_0, &v_1);
      fx_str_t slit_1 = FX_MAKE_STR("");
      FX_CALL(
         _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
            &sum_id_0, _fx_g20C_gen_code__CTypCInt, &v_0, &slit_1, &v_1, ccode_0, loc_0, &v_2, 0), _fx_catch_1);
      FX_COPY_PTR(v_2.t0, &sum_exp_0);
      FX_COPY_PTR(v_2.t1, &ccode_1);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, loc_0, &bool_ctx_0);
      _fx_N17C_form__cbinary_t v_11;
      _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_11);
      FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, loc_0, &v_3, 0), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &v_11, sum_exp_0, v_3, &bool_ctx_0, &v_4), _fx_catch_1);
      _fx_N17C_form__cbinary_t v_12;
      _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_12);
      FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(n_0, loc_0, &v_5, 0), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &v_12, sum_exp_0, v_5, &bool_ctx_0, &v_6), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g22C_gen_code__COpLogicOr, v_4, v_6, &bool_ctx_0, &check_exp_0), _fx_catch_1);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_0, 0, true, &v_7), _fx_catch_1);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(check_exp_0, v_7, false, &v_7), _fx_catch_1);
      FX_CALL(
         _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g28C_form__std_FX_CHECK_EQ_SIZE, v_7, _fx_g20C_gen_code__CTypVoid, loc_0, &check_call_0, 0), _fx_catch_1);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(check_call_0, &v_8), _fx_catch_1);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_8, ccode_1, true, fx_result), _fx_catch_1);

   _fx_catch_1: ;
      if (v_8) {
         _fx_free_N15C_form__cstmt_t(&v_8);
      }
      if (check_call_0) {
         _fx_free_N14C_form__cexp_t(&check_call_0);
      }
      if (v_7) {
         _fx_free_LN14C_form__cexp_t(&v_7);
      }
      if (check_exp_0) {
         _fx_free_N14C_form__cexp_t(&check_exp_0);
      }
      if (v_6) {
         _fx_free_N14C_form__cexp_t(&v_6);
      }
      if (v_5) {
         _fx_free_N14C_form__cexp_t(&v_5);
      }
      if (v_4) {
         _fx_free_N14C_form__cexp_t(&v_4);
      }
      if (v_3) {
         _fx_free_N14C_form__cexp_t(&v_3);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&bool_ctx_0);
      if (ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&ccode_1);
      }
      if (sum_exp_0) {
         _fx_free_N14C_form__cexp_t(&sum_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_2);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_1);
      _fx_free_R16Ast__val_flags_t(&v_0);
      if (sum_checks_0) {
         _fx_free_N14C_form__cexp_t(&sum_checks_0);
      }
      if (rest_0) {
         _fx_free_LN14C_form__cexp_t(&rest_0);
      }
      if (__fold_result___0) {
         _fx_free_N14C_form__cexp_t(&__fold_result___0);
      }
   }
   else {
      FX_COPY_PTR(ccode_0, fx_result);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_N14C_form__cexp_t_data_t* lbl_0,
   struct _fx_LT2R9Ast__id_tN13K_form__dom_t_data_t* idoml_0,
   struct _fx_LR9Ast__id_t_data_t* at_ids_0,
   int_ for_idx_0,
   int_ nfors_0,
   int_ ndims_0,
   int_ dims_ofs_0,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* nested_e_idoml_0,
   struct _fx_LN15C_form__cstmt_t_data_t* init_ccode_0,
   struct _fx_R10Ast__loc_t* loc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t*
      fx_result,
   void* fx_fv)
{
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t atom2cexp__0 = {0};
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti
      atom2cexp_0 = {0};
   fx_str_t v_0 = {0};
   fx_exn_t v_1 = {0};
   _fx_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_2 = {0};
   _fx_LT2R9Ast__id_tN13K_form__dom_t idoml_1 = 0;
   _fx_LR9Ast__id_t at_ids_1 = 0;
   _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t
      __fold_result___0 = {0};
   _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t
      v_3 = {0};
   _fx_LN14C_form__cexp_t list_exps_0 = 0;
   _fx_LN14C_form__cexp_t i_exps_0 = 0;
   _fx_LN14C_form__cexp_t n_exps_0 = 0;
   _fx_LN14C_form__cexp_t for_checks_0 = 0;
   _fx_LN14C_form__cexp_t incr_exps_0 = 0;
   _fx_LN14C_form__cexp_t init_checks_0 = 0;
   _fx_LN15C_form__cstmt_t init_ccode_1 = 0;
   _fx_LN15C_form__cstmt_t pre_body_ccode_0 = 0;
   _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t body_elems_0 = 0;
   _fx_LN14C_form__cexp_t post_checks_0 = 0;
   _fx_LN14C_form__cexp_t v_4 = 0;
   _fx_LN15C_form__cstmt_t init_ccode_2 = 0;
   _fx_Ta2LN15C_form__cstmt_t v_5 = {0};
   _fx_LN15C_form__cstmt_t v_6 = 0;
   _fx_LN15C_form__cstmt_t init_ccode_3 = 0;
   _fx_LN15C_form__cstmt_t pre_body_ccode_1 = 0;
   _fx_LN14C_form__cexp_t post_checks_1 = 0;
   _fx_LN14C_form__cexp_t post_checks_2 = 0;
   _fx_N14C_form__cexp_t v_7 = 0;
   _fx_N14C_form__cexp_t v_8 = 0;
   _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_9 = {0};
   _fx_N14C_form__cexp_t v_10 = 0;
   _fx_LN15C_form__cstmt_t post_ccode_0 = 0;
   _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t __fold_result___1 = {0};
   _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_11 = {0};
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t for_headers_0 = 0;
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t for_headers_1 = 0;
   _fx_Nt6option1N14C_form__cexp_t __fold_result___2 = {0};
   _fx_LN14C_form__cexp_t v_12 = 0;
   _fx_Nt6option1N14C_form__cexp_t check_exp_opt_0 = {0};
   _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_13 = {0};
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_14 = 0;
   int fx_status = 0;
   _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t*)
         fx_fv;
   _fx_rLrR23C_gen_code__block_ctx_t block_stack_ref_1 = cv_0->t0;
   _fx_rNt10Hashset__t1R9Ast__id_t defined_syms_ref_1 = cv_0->t1;
   _fx_rLN15C_form__cstmt_t fwd_fdecls_ref_1 = cv_0->t2;
   _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t i2e_ref_1 = cv_0->t3;
   int_* km_idx_1 = &cv_0->t4;
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &atom2cexp__0);
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &atom2cexp_0);
   _fx_R10Ast__loc_t for_loc_0;
   FX_CALL(_fx_M3AstFM13get_start_locRM5loc_t1RM5loc_t(loc_0, &for_loc_0, 0), _fx_cleanup);
   _fx_R10Ast__loc_t end_for_loc_0;
   FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(loc_0, &end_for_loc_0, 0), _fx_cleanup);
   if (idoml_0 == 0) {
      fx_str_t slit_0 = FX_MAKE_STR("empty list of for iteration values");
      FX_CALL(_fx_M10C_gen_codeFM11for_err_msgS4iiiS(for_idx_0, nfors_0, -1, &slit_0, &v_0, 0), _fx_cleanup);
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_0, &v_1, 0), _fx_cleanup);
      FX_THROW(&v_1, false, _fx_cleanup);
   }
   if (at_ids_0 == 0) {
      _fx_make_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(idoml_0, at_ids_0, &v_2);
   }
   else {
      bool __fold_result___3 = false;
      _fx_LT2R9Ast__id_tN13K_form__dom_t lst_0 = idoml_0;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_N13K_form__dom_t dom_i_0 = {0};
         _fx_T2R9Ast__id_tN13K_form__dom_t* __pat___0 = &lst_0->hd;
         _fx_copy_N13K_form__dom_t(&__pat___0->t1, &dom_i_0);
         int tag_0 = dom_i_0.tag;
         bool v_15;
         if (tag_0 == 1) {
            _fx_N14K_form__atom_t* v_16 = &dom_i_0.u.DomainElem;
            if (v_16->tag == 1) {
               _fx_N14K_form__ktyp_t v_17 = 0;
               _fx_N14K_form__ktyp_t v_18 = 0;
               FX_CALL(_fx_M6K_formFM12get_idk_ktypN14K_form__ktyp_t2R9Ast__id_tR10Ast__loc_t(&v_16->u.AtomId, loc_0, &v_17, 0),
                  _fx_catch_0);
               FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(v_17, loc_0, &v_18, 0),
                  _fx_catch_0);
               if (FX_REC_VARIANT_TAG(v_18) == 19) {
                  v_15 = false;
               }
               else {
                  v_15 = true;
               }
               FX_CHECK_EXN(_fx_catch_0);

            _fx_catch_0: ;
               if (v_18) {
                  _fx_free_N14K_form__ktyp_t(&v_18);
               }
               if (v_17) {
                  _fx_free_N14K_form__ktyp_t(&v_17);
               }
               goto _fx_endmatch_0;
            }
         }
         if (tag_0 == 2) {
            _fx_N14K_form__atom_t* v_19 = &dom_i_0.u.DomainFast;
            if (v_19->tag == 1) {
               _fx_N14K_form__ktyp_t v_20 = 0;
               _fx_N14K_form__ktyp_t v_21 = 0;
               FX_CALL(_fx_M6K_formFM12get_idk_ktypN14K_form__ktyp_t2R9Ast__id_tR10Ast__loc_t(&v_19->u.AtomId, loc_0, &v_20, 0),
                  _fx_catch_1);
               FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(v_20, loc_0, &v_21, 0),
                  _fx_catch_1);
               if (FX_REC_VARIANT_TAG(v_21) == 19) {
                  v_15 = false;
               }
               else {
                  v_15 = true;
               }
               FX_CHECK_EXN(_fx_catch_1);

            _fx_catch_1: ;
               if (v_21) {
                  _fx_free_N14K_form__ktyp_t(&v_21);
               }
               if (v_20) {
                  _fx_free_N14K_form__ktyp_t(&v_20);
               }
               goto _fx_endmatch_0;
            }
         }
         if (tag_0 == 1) {
            _fx_N14K_form__atom_t* v_22 = &dom_i_0.u.DomainElem;
            if (v_22->tag == 2) {
               if (v_22->u.AtomLit.tag == 8) {
                  v_15 = false; goto _fx_endmatch_0;
               }
            }
         }
         if (tag_0 == 3) {
            _fx_N14K_form__atom_t* v_23 = &dom_i_0.u.DomainRange.t2;
            if (v_23->tag == 2) {
               _fx_N14K_form__klit_t* v_24 = &v_23->u.AtomLit;
               if (v_24->tag == 1) {
                  if (v_24->u.KLitInt == 1LL) {
                     v_15 = false; goto _fx_endmatch_0;
                  }
               }
            }
         }
         if (tag_0 == 3) {
            _fx_N14K_form__atom_t* v_25 = &dom_i_0.u.DomainRange.t1;
            if (v_25->tag == 2) {
               if (v_25->u.AtomLit.tag == 8) {
                  v_15 = false; goto _fx_endmatch_0;
               }
            }
         }
         v_15 = true;

      _fx_endmatch_0: ;
         FX_CHECK_EXN(_fx_catch_2);
         if (v_15) {
            __fold_result___3 = true; FX_BREAK(_fx_catch_2);
         }

      _fx_catch_2: ;
         _fx_free_N13K_form__dom_t(&dom_i_0);
         FX_CHECK_BREAK();
         FX_CHECK_EXN(_fx_cleanup);
      }
      bool have_good_idx_0 = __fold_result___3;
      if (have_good_idx_0 == true) {
         _fx_make_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(idoml_0, at_ids_0, &v_2); goto _fx_endmatch_1;
      }
      if (have_good_idx_0 == false) {
         if (at_ids_0 != 0) {
            if (at_ids_0->tl == 0) {
               _fx_N14K_form__klit_t v_26 = {0};
               _fx_N14K_form__atom_t v_27 = {0};
               _fx_N14K_form__klit_t v_28 = {0};
               _fx_N14K_form__atom_t v_29 = {0};
               _fx_N13K_form__dom_t v_30 = {0};
               _fx_T2R9Ast__id_tN13K_form__dom_t i_iter_0 = {0};
               _fx_LT2R9Ast__id_tN13K_form__dom_t v_31 = 0;
               _fx_M6K_formFM7KLitIntN14K_form__klit_t1l(0LL, &v_26);
               _fx_M6K_formFM7AtomLitN14K_form__atom_t1N14K_form__klit_t(&v_26, &v_27);
               _fx_M6K_formFM7KLitIntN14K_form__klit_t1l(1LL, &v_28);
               _fx_M6K_formFM7AtomLitN14K_form__atom_t1N14K_form__klit_t(&v_28, &v_29);
               _fx_M6K_formFM11DomainRangeN13K_form__dom_t3N14K_form__atom_tN14K_form__atom_tN14K_form__atom_t(&v_27,
                  &_fx_g17K_form___ALitVoid, &v_29, &v_30);
               _fx_make_T2R9Ast__id_tN13K_form__dom_t(&at_ids_0->hd, &v_30, &i_iter_0);
               FX_CALL(_fx_cons_LT2R9Ast__id_tN13K_form__dom_t(&i_iter_0, idoml_0, true, &v_31), _fx_catch_3);
               _fx_make_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(v_31, 0, &v_2);

            _fx_catch_3: ;
               if (v_31) {
                  _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&v_31);
               }
               _fx_free_T2R9Ast__id_tN13K_form__dom_t(&i_iter_0);
               _fx_free_N13K_form__dom_t(&v_30);
               _fx_free_N14K_form__atom_t(&v_29);
               _fx_free_N14K_form__klit_t(&v_28);
               _fx_free_N14K_form__atom_t(&v_27);
               _fx_free_N14K_form__klit_t(&v_26);
               goto _fx_endmatch_1;
            }
         }
      }
      fx_str_t v_32 = {0};
      fx_exn_t v_33 = {0};
      fx_str_t slit_1 = FX_MAKE_STR("here @ clause should contain just one scalar index");
      FX_CALL(_fx_M10C_gen_codeFM11for_err_msgS4iiiS(for_idx_0, nfors_0, 0, &slit_1, &v_32, 0), _fx_catch_4);
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_32, &v_33, 0), _fx_catch_4);
      FX_THROW(&v_33, false, _fx_catch_4);

   _fx_catch_4: ;
      fx_free_exn(&v_33);
      FX_FREE_STR(&v_32);

   _fx_endmatch_1: ;
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(v_2.t0, &idoml_1);
   FX_COPY_PTR(v_2.t1, &at_ids_1);
   _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
      0, 0, 0, 0, 0, 0, init_ccode_0, 0, 0, 0, &__fold_result___0);
   int_ k_0 = 0;
   _fx_LT2R9Ast__id_tN13K_form__dom_t lst_1 = idoml_1;
   for (; lst_1; lst_1 = lst_1->tl, k_0 += 1) {
      _fx_N13K_form__dom_t dom_i_1 = {0};
      _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t
         v_34 = {0};
      _fx_LN14C_form__cexp_t list_exps_1 = 0;
      _fx_LN14C_form__cexp_t i_exps_1 = 0;
      _fx_LN14C_form__cexp_t n_exps_1 = 0;
      _fx_LN14C_form__cexp_t for_checks_1 = 0;
      _fx_LN14C_form__cexp_t incr_exps_1 = 0;
      _fx_LN14C_form__cexp_t init_checks_1 = 0;
      _fx_LN15C_form__cstmt_t init_ccode_4 = 0;
      _fx_LN15C_form__cstmt_t pre_body_ccode_2 = 0;
      _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t body_elems_1 = 0;
      _fx_LN14C_form__cexp_t post_checks_3 = 0;
      _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t
         v_35 = {0};
      _fx_LN14C_form__cexp_t lists_i_0 = 0;
      _fx_LN14C_form__cexp_t i_exps_2 = 0;
      _fx_LN14C_form__cexp_t n_exps_2 = 0;
      _fx_LN14C_form__cexp_t for_checks_2 = 0;
      _fx_LN14C_form__cexp_t incr_exps_2 = 0;
      _fx_LN14C_form__cexp_t init_checks_2 = 0;
      _fx_LN15C_form__cstmt_t init_ccode_5 = 0;
      _fx_LN15C_form__cstmt_t pre_body_ccode_3 = 0;
      _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t body_elems_2 = 0;
      _fx_LN14C_form__cexp_t post_checks_4 = 0;
      _fx_LN14C_form__cexp_t v_36 = 0;
      _fx_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t
         v_37 = {0};
      _fx_T2R9Ast__id_tN13K_form__dom_t* __pat___1 = &lst_1->hd;
      _fx_R9Ast__id_t iter_val_i_0 = __pat___1->t0;
      _fx_copy_N13K_form__dom_t(&__pat___1->t1, &dom_i_1);
      _fx_copy_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         &__fold_result___0, &v_34);
      FX_COPY_PTR(v_34.t0, &list_exps_1);
      FX_COPY_PTR(v_34.t1, &i_exps_1);
      FX_COPY_PTR(v_34.t2, &n_exps_1);
      FX_COPY_PTR(v_34.t3, &for_checks_1);
      FX_COPY_PTR(v_34.t4, &incr_exps_1);
      FX_COPY_PTR(v_34.t5, &init_checks_1);
      FX_COPY_PTR(v_34.t6, &init_ccode_4);
      FX_COPY_PTR(v_34.t7, &pre_body_ccode_2);
      FX_COPY_PTR(v_34.t8, &body_elems_1);
      FX_COPY_PTR(v_34.t9, &post_checks_3);
      bool res_0;
      FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&iter_val_i_0, &_fx_g9Ast__noid, &res_0, 0), _fx_catch_26);
      _fx_R9Ast__id_t iter_val_i_1;
      if (res_0) {
         iter_val_i_1 = iter_val_i_0;
      }
      else {
         fx_str_t slit_2 = FX_MAKE_STR("i");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_2, &iter_val_i_1, 0), _fx_catch_26);
      }
      int tag_1 = dom_i_1.tag;
      if (tag_1 == 3) {
         _fx_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t v_38 = {0};
         _fx_N14C_form__cexp_t d_exp_0 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_6 = 0;
         _fx_Ta3N14K_form__atom_t* vcase_0 = &dom_i_1.u.DomainRange;
         _fx_N14K_form__atom_t* delta_0 = &vcase_0->t2;
         _fx_N14K_form__atom_t* b_0 = &vcase_0->t1;
         _fx_N14K_form__atom_t* a_0 = &vcase_0->t0;
         int tag_2 = delta_0->tag;
         if (tag_2 == 2) {
            _fx_N14K_form__klit_t* v_39 = &delta_0->u.AtomLit;
            if (v_39->tag == 1) {
               if (v_39->u.KLitInt == 0LL) {
                  fx_str_t v_40 = {0};
                  fx_exn_t v_41 = {0};
                  fx_str_t slit_3 = FX_MAKE_STR("the iteration step is zero");
                  FX_CALL(_fx_M10C_gen_codeFM11for_err_msgS4iiiS(for_idx_0, nfors_0, k_0, &slit_3, &v_40, 0), _fx_catch_5);
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&for_loc_0, &v_40, &v_41, 0), _fx_catch_5);
                  FX_THROW(&v_41, false, _fx_catch_5);

               _fx_catch_5: ;
                  fx_free_exn(&v_41);
                  FX_FREE_STR(&v_40);
                  goto _fx_endmatch_2;
               }
            }
         }
         if (tag_2 == 2) {
            _fx_N14K_form__klit_t* v_42 = &delta_0->u.AtomLit;
            if (v_42->tag == 1) {
               _fx_N14C_form__cexp_t v_43 = 0;
               FX_CALL(_fx_M6C_formFM13make_int__expN14C_form__cexp_t2lR10Ast__loc_t(v_42->u.KLitInt, &for_loc_0, &v_43, 0),
                  _fx_catch_6);
               _fx_make_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t(
                  &_fx_g21C_gen_code__COpAugAdd, &_fx_g18C_gen_code__COpAdd, v_43, init_ccode_4, &v_38);

            _fx_catch_6: ;
               if (v_43) {
                  _fx_free_N14C_form__cexp_t(&v_43);
               }
               goto _fx_endmatch_2;
            }
         }
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_44 = {0};
         _fx_N14C_form__cexp_t d_exp_1 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_7 = 0;
         _fx_LN14C_form__cexp_t v_45 = 0;
         _fx_N14C_form__cexp_t v_46 = 0;
         _fx_N15C_form__cstmt_t v_47 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_8 = 0;
         FX_CALL(atom2cexp__0.fp(delta_0, true, init_ccode_4, &for_loc_0, &v_44, atom2cexp__0.fcv), _fx_catch_7);
         FX_COPY_PTR(v_44.t0, &d_exp_1);
         FX_COPY_PTR(v_44.t1, &init_ccode_7);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_0, 0, true, &v_45), _fx_catch_7);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(d_exp_1, v_45, false, &v_45), _fx_catch_7);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g30C_form__std_FX_CHECK_ZERO_STEP, v_45, _fx_g20C_gen_code__CTypVoid, &for_loc_0, &v_46, 0), _fx_catch_7);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_46, &v_47), _fx_catch_7);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_47, init_ccode_7, true, &init_ccode_8), _fx_catch_7);
         _fx_make_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t(&_fx_g21C_gen_code__COpAugAdd,
            &_fx_g18C_gen_code__COpAdd, d_exp_1, init_ccode_8, &v_38);

      _fx_catch_7: ;
         if (init_ccode_8) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_8);
         }
         if (v_47) {
            _fx_free_N15C_form__cstmt_t(&v_47);
         }
         if (v_46) {
            _fx_free_N14C_form__cexp_t(&v_46);
         }
         if (v_45) {
            _fx_free_LN14C_form__cexp_t(&v_45);
         }
         if (init_ccode_7) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_7);
         }
         if (d_exp_1) {
            _fx_free_N14C_form__cexp_t(&d_exp_1);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_44);

      _fx_endmatch_2: ;
         FX_CHECK_EXN(_fx_catch_13);
         _fx_N17C_form__cbinary_t aug_add_delta_0 = v_38.t0;
         _fx_N17C_form__cbinary_t add_delta_0 = v_38.t1;
         FX_COPY_PTR(v_38.t2, &d_exp_0);
         FX_COPY_PTR(v_38.t3, &init_ccode_6);
         if (b_0->tag == 2) {
            if (b_0->u.AtomLit.tag == 8) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_48 = {0};
               _fx_N14C_form__cexp_t a_exp_0 = 0;
               _fx_LN15C_form__cstmt_t init_ccode_9 = 0;
               _fx_R16Ast__val_flags_t v_49 = {0};
               _fx_Nt6option1N14C_form__cexp_t v_50 = {0};
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_51 = {0};
               _fx_N14C_form__cexp_t i_exp_0 = 0;
               _fx_LN15C_form__cstmt_t init_ccode_10 = 0;
               _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_52 = {0};
               _fx_N14C_form__cexp_t incr_i_exp_0 = 0;
               _fx_LN14C_form__cexp_t v_53 = 0;
               FX_CALL(atom2cexp__0.fp(a_0, false, init_ccode_6, &for_loc_0, &v_48, atom2cexp__0.fcv), _fx_catch_8);
               FX_COPY_PTR(v_48.t0, &a_exp_0);
               FX_COPY_PTR(v_48.t1, &init_ccode_9);
               FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_49, 0), _fx_catch_8);
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(a_exp_0, &v_50);
               fx_str_t slit_4 = FX_MAKE_STR("");
               FX_CALL(
                  _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                     &iter_val_i_1, _fx_g19C_gen_code__CTypInt, &v_49, &slit_4, &v_50, init_ccode_9, &for_loc_0, &v_51, 0),
                  _fx_catch_8);
               FX_COPY_PTR(v_51.t0, &i_exp_0);
               FX_COPY_PTR(v_51.t1, &init_ccode_10);
               _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypVoid, &for_loc_0, &v_52);
               FX_CALL(
                  _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                     &aug_add_delta_0, i_exp_0, d_exp_0, &v_52, &incr_i_exp_0), _fx_catch_8);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(incr_i_exp_0, incr_exps_1, true, &v_53), _fx_catch_8);
               _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
                  0, i_exps_1, n_exps_1, for_checks_1, v_53, init_checks_1, init_ccode_10, pre_body_ccode_2, body_elems_1,
                  post_checks_3, &v_35);

            _fx_catch_8: ;
               if (v_53) {
                  _fx_free_LN14C_form__cexp_t(&v_53);
               }
               if (incr_i_exp_0) {
                  _fx_free_N14C_form__cexp_t(&incr_i_exp_0);
               }
               _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_52);
               if (init_ccode_10) {
                  _fx_free_LN15C_form__cstmt_t(&init_ccode_10);
               }
               if (i_exp_0) {
                  _fx_free_N14C_form__cexp_t(&i_exp_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_51);
               _fx_free_Nt6option1N14C_form__cexp_t(&v_50);
               _fx_free_R16Ast__val_flags_t(&v_49);
               if (init_ccode_9) {
                  _fx_free_LN15C_form__cstmt_t(&init_ccode_9);
               }
               if (a_exp_0) {
                  _fx_free_N14C_form__cexp_t(&a_exp_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_48);
               goto _fx_endmatch_6;
            }
         }
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_54 = {0};
         _fx_N14C_form__cexp_t a_exp_1 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_11 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_55 = {0};
         _fx_N14C_form__cexp_t b_exp_0 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_12 = 0;
         _fx_N14C_form__cexp_t calc_n_exp_0 = 0;
         _fx_LN14C_form__cexp_t v_56 = 0;
         _fx_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_57 = {0};
         _fx_N14C_form__cexp_t i_exp_1 = 0;
         _fx_LN14C_form__cexp_t i_exps_3 = 0;
         _fx_LN14C_form__cexp_t n_exps_3 = 0;
         _fx_LN14C_form__cexp_t init_checks_3 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_13 = 0;
         _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t body_elems_3 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_58 = {0};
         _fx_N14C_form__cexp_t v_59 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_60 = {0};
         _fx_N14C_form__cexp_t calc_i_exp_0 = 0;
         _fx_R16Ast__val_flags_t v_61 = {0};
         _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_62 = {0};
         FX_CALL(atom2cexp__0.fp(a_0, true, init_ccode_6, &for_loc_0, &v_54, atom2cexp__0.fcv), _fx_catch_12);
         FX_COPY_PTR(v_54.t0, &a_exp_1);
         FX_COPY_PTR(v_54.t1, &init_ccode_11);
         FX_CALL(atom2cexp__0.fp(b_0, true, init_ccode_11, &for_loc_0, &v_55, atom2cexp__0.fcv), _fx_catch_12);
         FX_COPY_PTR(v_55.t0, &b_exp_0);
         FX_COPY_PTR(v_55.t1, &init_ccode_12);
         bool is_canonical_for_0;
         if (a_0->tag == 2) {
            if (delta_0->tag == 2) {
               _fx_N14K_form__klit_t* v_63 = &a_0->u.AtomLit;
               if (v_63->tag == 1) {
                  if (v_63->u.KLitInt == 0LL) {
                     _fx_N14K_form__klit_t* v_64 = &delta_0->u.AtomLit;
                     if (v_64->tag == 1) {
                        if (v_64->u.KLitInt == 1LL) {
                           is_canonical_for_0 = true; goto _fx_endmatch_3;
                        }
                     }
                  }
               }
            }
         }
         is_canonical_for_0 = false;

      _fx_endmatch_3: ;
         FX_CHECK_EXN(_fx_catch_12);
         if (is_canonical_for_0) {
            FX_COPY_PTR(b_exp_0, &calc_n_exp_0);
         }
         else {
            FX_CALL(_fx_cons_LN14C_form__cexp_t(d_exp_0, 0, true, &v_56), _fx_catch_12);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(b_exp_0, v_56, false, &v_56), _fx_catch_12);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(a_exp_1, v_56, false, &v_56), _fx_catch_12);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g25C_form__std_FX_LOOP_COUNT, v_56, _fx_g19C_gen_code__CTypInt, &for_loc_0, &calc_n_exp_0, 0),
               _fx_catch_12);
         }
         if (n_exps_1 != 0) {
            if (i_exps_1 != 0) {
               _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_65 = {0};
               _fx_N14C_form__cexp_t v_66 = 0;
               _fx_LN14C_form__cexp_t v_67 = 0;
               _fx_N17C_form__cbinary_t v_68;
               _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_68);
               _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &for_loc_0, &v_65);
               FX_CALL(
                  _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                     &v_68, n_exps_1->hd, calc_n_exp_0, &v_65, &v_66), _fx_catch_9);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_66, init_checks_1, true, &v_67), _fx_catch_9);
               _fx_make_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(true,
                  i_exps_1->hd, i_exps_1, n_exps_1, v_67, init_ccode_12, &v_57);

            _fx_catch_9: ;
               if (v_67) {
                  _fx_free_LN14C_form__cexp_t(&v_67);
               }
               if (v_66) {
                  _fx_free_N14C_form__cexp_t(&v_66);
               }
               _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_65);
               goto _fx_endmatch_5;
            }
         }
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_69 = {0};
         _fx_R16Ast__val_flags_t v_70 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_71 = {0};
         _fx_N14C_form__cexp_t n_exp_0 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_14 = 0;
         _fx_R16Ast__val_flags_t v_72 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_73 = {0};
         _fx_N14C_form__cexp_t i_exp_2 = 0;
         _fx_LN14C_form__cexp_t v_74 = 0;
         _fx_LN14C_form__cexp_t v_75 = 0;
         _fx_T2BR9Ast__id_t v_76;
         if (a_0->tag == 2) {
            if (delta_0->tag == 2) {
               _fx_N14K_form__klit_t* v_77 = &a_0->u.AtomLit;
               if (v_77->tag == 1) {
                  if (v_77->u.KLitInt == 0LL) {
                     _fx_N14K_form__klit_t* v_78 = &delta_0->u.AtomLit;
                     if (v_78->tag == 1) {
                        if (v_78->u.KLitInt == 1LL) {
                           _fx_T2BR9Ast__id_t tup_0 = { false, iter_val_i_1 }; v_76 = tup_0; goto _fx_endmatch_4;
                        }
                     }
                  }
               }
            }
         }
         fx_str_t v_79 = {0};
         FX_CALL(_fx_M3AstFM2ppS1RM4id_t(&iter_val_i_1, &v_79, 0), _fx_catch_10);
         _fx_R9Ast__id_t v_80;
         FX_CALL(
            _fx_M10C_gen_codeFM11get_iter_idR9Ast__id_t7iLR9Ast__id_tSiiR10Ast__loc_ti(0, at_ids_1, &v_79, for_idx_0, km_idx_0,
               loc_0, nfors_0, &v_80, 0), _fx_catch_10);
         _fx_T2BR9Ast__id_t tup_1 = { true, v_80 };
         v_76 = tup_1;

      _fx_catch_10: ;
         FX_FREE_STR(&v_79);

      _fx_endmatch_4: ;
         FX_CHECK_EXN(_fx_catch_11);
         bool add_pair_0 = v_76.t0;
         _fx_R9Ast__id_t i_id_0 = v_76.t1;
         bool res_1;
         FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&i_id_0, &_fx_g9Ast__noid, &res_1, 0), _fx_catch_11);
         _fx_R9Ast__id_t i_id_1;
         if (res_1) {
            i_id_1 = i_id_0;
         }
         else {
            fx_str_t slit_5 = FX_MAKE_STR("i");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_5, &i_id_1, 0), _fx_catch_11);
         }
         bool v_81;
         if (is_canonical_for_0) {
            FX_CALL(_fx_M10C_gen_codeFM24is_immutable_atomic_cexpB1N14C_form__cexp_t(b_exp_0, &v_81, 0), _fx_catch_11);
         }
         else {
            v_81 = false;
         }
         if (v_81) {
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(b_exp_0, init_ccode_12, &v_69);
         }
         else {
            _fx_R9Ast__id_t v_82;
            fx_str_t slit_6 = FX_MAKE_STR("n");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_6, &v_82, 0), _fx_catch_11);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_70, 0), _fx_catch_11);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(calc_n_exp_0, &v_71);
            FX_CALL(
               _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  &v_82, _fx_g19C_gen_code__CTypInt, &v_70, &v_71, init_ccode_12, &for_loc_0, block_stack_ref_0, &v_69, 0),
               _fx_catch_11);
         }
         FX_COPY_PTR(v_69.t0, &n_exp_0);
         FX_COPY_PTR(v_69.t1, &init_ccode_14);
         FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_72, 0), _fx_catch_11);
         FX_CALL(
            _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               &i_id_1, _fx_g19C_gen_code__CTypInt, &v_72, &_fx_g18C_gen_code__None2_, 0, &for_loc_0, block_stack_ref_0, &v_73,
               0), _fx_catch_11);
         FX_COPY_PTR(v_73.t0, &i_exp_2);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_2, i_exps_1, true, &v_74), _fx_catch_11);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(n_exp_0, n_exps_1, true, &v_75), _fx_catch_11);
         _fx_make_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(add_pair_0,
            i_exp_2, v_74, v_75, init_checks_1, init_ccode_14, &v_57);

      _fx_catch_11: ;
         if (v_75) {
            _fx_free_LN14C_form__cexp_t(&v_75);
         }
         if (v_74) {
            _fx_free_LN14C_form__cexp_t(&v_74);
         }
         if (i_exp_2) {
            _fx_free_N14C_form__cexp_t(&i_exp_2);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_73);
         _fx_free_R16Ast__val_flags_t(&v_72);
         if (init_ccode_14) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_14);
         }
         if (n_exp_0) {
            _fx_free_N14C_form__cexp_t(&n_exp_0);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_71);
         _fx_free_R16Ast__val_flags_t(&v_70);
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_69);

      _fx_endmatch_5: ;
         FX_CHECK_EXN(_fx_catch_12);
         bool add_elem_0 = v_57.t0;
         FX_COPY_PTR(v_57.t1, &i_exp_1);
         FX_COPY_PTR(v_57.t2, &i_exps_3);
         FX_COPY_PTR(v_57.t3, &n_exps_3);
         FX_COPY_PTR(v_57.t4, &init_checks_3);
         FX_COPY_PTR(v_57.t5, &init_ccode_13);
         if (!add_elem_0) {
            FX_COPY_PTR(body_elems_1, &body_elems_3);
         }
         else {
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g19C_gen_code__CTypInt, &for_loc_0, &v_58);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g18C_gen_code__COpMul, i_exp_1, d_exp_0, &v_58, &v_59), _fx_catch_12);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g19C_gen_code__CTypInt, &for_loc_0, &v_60);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &add_delta_0, a_exp_1, v_59, &v_60, &calc_i_exp_0), _fx_catch_12);
            FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_61, 0), _fx_catch_12);
            _fx_make_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&iter_val_i_1, calc_i_exp_0, &v_61, &v_62);
            FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_62, body_elems_1, true, &body_elems_3),
               _fx_catch_12);
         }
         _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
            0, i_exps_3, n_exps_3, for_checks_1, incr_exps_1, init_checks_3, init_ccode_13, pre_body_ccode_2, body_elems_3,
            post_checks_3, &v_35);

      _fx_catch_12: ;
         _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_62);
         _fx_free_R16Ast__val_flags_t(&v_61);
         if (calc_i_exp_0) {
            _fx_free_N14C_form__cexp_t(&calc_i_exp_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_60);
         if (v_59) {
            _fx_free_N14C_form__cexp_t(&v_59);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_58);
         if (body_elems_3) {
            _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&body_elems_3);
         }
         if (init_ccode_13) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_13);
         }
         if (init_checks_3) {
            _fx_free_LN14C_form__cexp_t(&init_checks_3);
         }
         if (n_exps_3) {
            _fx_free_LN14C_form__cexp_t(&n_exps_3);
         }
         if (i_exps_3) {
            _fx_free_LN14C_form__cexp_t(&i_exps_3);
         }
         if (i_exp_1) {
            _fx_free_N14C_form__cexp_t(&i_exp_1);
         }
         _fx_free_T6BN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_57);
         if (v_56) {
            _fx_free_LN14C_form__cexp_t(&v_56);
         }
         if (calc_n_exp_0) {
            _fx_free_N14C_form__cexp_t(&calc_n_exp_0);
         }
         if (init_ccode_12) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_12);
         }
         if (b_exp_0) {
            _fx_free_N14C_form__cexp_t(&b_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_55);
         if (init_ccode_11) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_11);
         }
         if (a_exp_1) {
            _fx_free_N14C_form__cexp_t(&a_exp_1);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_54);

      _fx_endmatch_6: ;
         FX_CHECK_EXN(_fx_catch_13);

      _fx_catch_13: ;
         if (init_ccode_6) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_6);
         }
         if (d_exp_0) {
            _fx_free_N14C_form__cexp_t(&d_exp_0);
         }
         _fx_free_T4N17C_form__cbinary_tN17C_form__cbinary_tN14C_form__cexp_tLN15C_form__cstmt_t(&v_38);
      }
      else if (tag_1 == 1) {
         _fx_N14K_form__ktyp_t ktyp_0 = 0;
         _fx_N14C_form__ctyp_t ctyp_0 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_83 = {0};
         _fx_N14K_form__atom_t v_84 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_85 = {0};
         _fx_N14C_form__cexp_t src_exp_0 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_15 = 0;
         _fx_rNt6option1N14C_form__cexp_t v_86 = 0;
         fx_str_t v_87 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_88 = {0};
         _fx_N14C_form__cexp_t col_exp_0 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_16 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_17 = 0;
         _fx_N14C_form__cexp_t col_exp_1 = 0;
         _fx_LN15C_form__cstmt_t init_ccode_18 = 0;
         _fx_N14K_form__ktyp_t v_89 = 0;
         _fx_N14K_form__atom_t* a_1 = &dom_i_1.u.DomainElem;
         _fx_R9Ast__id_t col__0;
         if (a_1->tag == 1) {
            col__0 = a_1->u.AtomId;
         }
         else {
            col__0 = _fx_g9Ast__noid;
         }
         FX_CHECK_EXN(_fx_catch_24);
         FX_CALL(_fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(a_1, &for_loc_0, &ktyp_0, 0),
            _fx_catch_24);
         FX_CALL(_fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_0, &for_loc_0, &ctyp_0, 0),
            _fx_catch_24);
         bool v_90;
         bool res_2;
         FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&col__0, &_fx_g9Ast__noid, &res_2, 0), _fx_catch_24);
         if (res_2) {
            bool __fold_result___4 = false;
            _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t lst_2 = nested_e_idoml_0;
            for (; lst_2; lst_2 = lst_2->tl) {
               _fx_N14K_form__kexp_t e_0 = 0;
               _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* __pat___2 = &lst_2->hd;
               FX_COPY_PTR(__pat___2->t0, &e_0);
               bool v_91;
               FX_CALL(_fx_M10C_gen_codeFM14occurs_id_kexpB2R9Ast__id_tN14K_form__kexp_t(&col__0, e_0, &v_91, 0), _fx_catch_14);
               if (v_91) {
                  __fold_result___4 = true; FX_BREAK(_fx_catch_14);
               }

            _fx_catch_14: ;
               if (e_0) {
                  _fx_free_N14K_form__kexp_t(&e_0);
               }
               FX_CHECK_BREAK();
               FX_CHECK_EXN(_fx_catch_24);
            }
            v_90 = __fold_result___4;
         }
         else {
            v_90 = false;
         }
         if (v_90) {
            _fx_M6K_formFM6AtomIdN14K_form__atom_t1R9Ast__id_t(&col__0, &v_84);
            FX_CALL(
               atom2cexp_0.fp(&v_84, init_ccode_4, &for_loc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                  i2e_ref_0, km_idx_0, &v_85, atom2cexp_0.fcv), _fx_catch_24);
            FX_COPY_PTR(v_85.t0, &src_exp_0);
            FX_COPY_PTR(v_85.t1, &init_ccode_15);
            FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_86), _fx_catch_24);
            FX_CALL(_fx_M3AstFM2ppS1RM4id_t(&col__0, &v_87, 0), _fx_catch_24);
            FX_CALL(
               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                  v_86, &v_87, ctyp_0, init_ccode_15, &for_loc_0, block_stack_ref_0, km_idx_0, &v_88, 0), _fx_catch_24);
            FX_COPY_PTR(v_88.t0, &col_exp_0);
            FX_COPY_PTR(v_88.t1, &init_ccode_16);
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  src_exp_0, col_exp_0, ctyp_0, init_ccode_16, &for_loc_0, &init_ccode_17, 0), _fx_catch_24);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(col_exp_0, init_ccode_17, &v_83);
         }
         else {
            FX_CALL(atom2cexp__0.fp(a_1, true, init_ccode_4, &for_loc_0, &v_83, atom2cexp__0.fcv), _fx_catch_24);
         }
         FX_COPY_PTR(v_83.t0, &col_exp_1);
         FX_COPY_PTR(v_83.t1, &init_ccode_18);
         FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_0, &for_loc_0, &v_89, 0),
            _fx_catch_24);
         int tag_3 = FX_REC_VARIANT_TAG(v_89);
         if (tag_3 == 19) {
            _fx_R16Ast__val_flags_t v_92 = {0};
            _fx_Nt6option1N14C_form__cexp_t v_93 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_94 = {0};
            _fx_N14C_form__cexp_t l_exp_0 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_19 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_95 = {0};
            _fx_N14C_form__cexp_t not_l_exp_0 = 0;
            _fx_N14C_form__cexp_t v_96 = 0;
            _fx_N14C_form__cexp_t l_next_exp_0 = 0;
            _fx_N14C_form__ctyp_t c_et_0 = 0;
            _fx_N14C_form__cexp_t get_hd_exp_0 = 0;
            _fx_R16Ast__val_flags_t hd_flags_0 = {0};
            _fx_LN14C_form__cexp_t v_97 = 0;
            _fx_LN14C_form__cexp_t v_98 = 0;
            _fx_LN14C_form__cexp_t v_99 = 0;
            _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_100 = {0};
            _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_101 = 0;
            _fx_LN14C_form__cexp_t v_102 = 0;
            _fx_N14K_form__ktyp_t et_0 = v_89->u.KTypList;
            _fx_R9Ast__id_t v_103;
            fx_str_t slit_7 = FX_MAKE_STR("lst");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_7, &v_103, 0), _fx_catch_15);
            FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_92, 0), _fx_catch_15);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(col_exp_1, &v_93);
            fx_str_t slit_8 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_103, ctyp_0, &v_92, &slit_8, &v_93, init_ccode_18, &for_loc_0, &v_94, 0), _fx_catch_15);
            FX_COPY_PTR(v_94.t0, &l_exp_0);
            FX_COPY_PTR(v_94.t1, &init_ccode_19);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &end_for_loc_0, &v_95);
            FX_CALL(
               _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g23C_gen_code__COpLogicNot, l_exp_0, &v_95, &not_l_exp_0), _fx_catch_15);
            _fx_R9Ast__id_t v_104;
            fx_str_t slit_9 = FX_MAKE_STR("tl");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_9, &v_104, 0), _fx_catch_15);
            FX_CALL(
               _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(l_exp_0, &v_104,
                  ctyp_0, &v_96, 0), _fx_catch_15);
            FX_CALL(
               _fx_M6C_formFM11make_assignN14C_form__cexp_t2N14C_form__cexp_tN14C_form__cexp_t(l_exp_0, v_96, &l_next_exp_0, 0),
               _fx_catch_15);
            FX_CALL(
               _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(et_0, &for_loc_0, &c_et_0, 0),
               _fx_catch_15);
            _fx_R9Ast__id_t v_105;
            fx_str_t slit_10 = FX_MAKE_STR("hd");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_10, &v_105, 0), _fx_catch_15);
            FX_CALL(
               _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(l_exp_0, &v_105,
                  c_et_0, &get_hd_exp_0, 0), _fx_catch_15);
            bool res_3;
            FX_CALL(_fx_M6K_formFM14is_ktyp_scalarB1N14K_form__ktyp_t(et_0, &res_3, 0), _fx_catch_15);
            if (res_3) {
               FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&hd_flags_0, 0), _fx_catch_15);
            }
            else {
               FX_CALL(_fx_M3AstFM21default_tempref_flagsRM11val_flags_t0(&hd_flags_0, 0), _fx_catch_15);
            }
            FX_CALL(_fx_cons_LN14C_form__cexp_t(l_exp_0, 0, true, &v_97), _fx_catch_15);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(l_exp_0, for_checks_1, true, &v_98), _fx_catch_15);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(l_next_exp_0, incr_exps_1, true, &v_99), _fx_catch_15);
            _fx_make_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&iter_val_i_1, get_hd_exp_0, &hd_flags_0, &v_100);
            FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_100, body_elems_1, true, &v_101),
               _fx_catch_15);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(not_l_exp_0, post_checks_3, true, &v_102), _fx_catch_15);
            _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
               v_97, i_exps_1, n_exps_1, v_98, v_99, init_checks_1, init_ccode_19, pre_body_ccode_2, v_101, v_102, &v_35);

         _fx_catch_15: ;
            if (v_102) {
               _fx_free_LN14C_form__cexp_t(&v_102);
            }
            if (v_101) {
               _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_101);
            }
            _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_100);
            if (v_99) {
               _fx_free_LN14C_form__cexp_t(&v_99);
            }
            if (v_98) {
               _fx_free_LN14C_form__cexp_t(&v_98);
            }
            if (v_97) {
               _fx_free_LN14C_form__cexp_t(&v_97);
            }
            _fx_free_R16Ast__val_flags_t(&hd_flags_0);
            if (get_hd_exp_0) {
               _fx_free_N14C_form__cexp_t(&get_hd_exp_0);
            }
            if (c_et_0) {
               _fx_free_N14C_form__ctyp_t(&c_et_0);
            }
            if (l_next_exp_0) {
               _fx_free_N14C_form__cexp_t(&l_next_exp_0);
            }
            if (v_96) {
               _fx_free_N14C_form__cexp_t(&v_96);
            }
            if (not_l_exp_0) {
               _fx_free_N14C_form__cexp_t(&not_l_exp_0);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_95);
            if (init_ccode_19) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_19);
            }
            if (l_exp_0) {
               _fx_free_N14C_form__cexp_t(&l_exp_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_94);
            _fx_free_Nt6option1N14C_form__cexp_t(&v_93);
            _fx_free_R16Ast__val_flags_t(&v_92);
         }
         else if (tag_3 == 10) {
            _fx_LN14C_form__cexp_t v_106 = 0;
            _fx_N14C_form__cexp_t calc_n_exp_1 = 0;
            _fx_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_107 = {0};
            _fx_N14C_form__cexp_t i_exp_3 = 0;
            _fx_LN14C_form__cexp_t i_exps_4 = 0;
            _fx_LN14C_form__cexp_t n_exps_4 = 0;
            _fx_LN14C_form__cexp_t init_checks_4 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_20 = 0;
            _fx_N14C_form__ctyp_t v_108 = 0;
            _fx_N14C_form__cexp_t get_chars_0 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_109 = {0};
            _fx_N14C_form__cexp_t get_char_i_0 = 0;
            _fx_R16Ast__val_flags_t v_110 = {0};
            _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_111 = {0};
            _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_112 = 0;
            FX_CALL(_fx_cons_LN14C_form__cexp_t(col_exp_1, 0, true, &v_106), _fx_catch_18);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g25C_form__std_FX_STR_LENGTH, v_106, _fx_g19C_gen_code__CTypInt, &for_loc_0, &calc_n_exp_1, 0),
               _fx_catch_18);
            if (n_exps_1 != 0) {
               if (i_exps_1 != 0) {
                  _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_113 = {0};
                  _fx_N14C_form__cexp_t v_114 = 0;
                  _fx_LN14C_form__cexp_t v_115 = 0;
                  _fx_N17C_form__cbinary_t v_116;
                  _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_116);
                  _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &for_loc_0, &v_113);
                  FX_CALL(
                     _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                        &v_116, n_exps_1->hd, calc_n_exp_1, &v_113, &v_114), _fx_catch_16);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_114, init_checks_1, true, &v_115), _fx_catch_16);
                  _fx_make_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(
                     i_exps_1->hd, i_exps_1, n_exps_1, v_115, init_ccode_18, &v_107);

               _fx_catch_16: ;
                  if (v_115) {
                     _fx_free_LN14C_form__cexp_t(&v_115);
                  }
                  if (v_114) {
                     _fx_free_N14C_form__cexp_t(&v_114);
                  }
                  _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_113);
                  goto _fx_endmatch_7;
               }
            }
            _fx_R16Ast__val_flags_t v_117 = {0};
            _fx_Nt6option1N14C_form__cexp_t v_118 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_119 = {0};
            _fx_N14C_form__cexp_t n_exp_1 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_21 = 0;
            fx_str_t v_120 = {0};
            _fx_R16Ast__val_flags_t v_121 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_122 = {0};
            _fx_N14C_form__cexp_t i_exp_4 = 0;
            _fx_LN14C_form__cexp_t v_123 = 0;
            _fx_LN14C_form__cexp_t v_124 = 0;
            _fx_R9Ast__id_t v_125;
            fx_str_t slit_11 = FX_MAKE_STR("len");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_11, &v_125, 0), _fx_catch_17);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_117, 0), _fx_catch_17);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(calc_n_exp_1, &v_118);
            FX_CALL(
               _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  &v_125, _fx_g19C_gen_code__CTypInt, &v_117, &v_118, init_ccode_18, &for_loc_0, block_stack_ref_0, &v_119, 0),
               _fx_catch_17);
            FX_COPY_PTR(v_119.t0, &n_exp_1);
            FX_COPY_PTR(v_119.t1, &init_ccode_21);
            FX_CALL(_fx_M10C_gen_codeFM3nthS2LSi(for_letters_0, dims_ofs_0, &v_120, 0), _fx_catch_17);
            _fx_R9Ast__id_t i_id_2;
            FX_CALL(
               _fx_M10C_gen_codeFM11get_iter_idR9Ast__id_t7iLR9Ast__id_tSiiR10Ast__loc_ti(0, at_ids_1, &v_120, for_idx_0,
                  km_idx_0, loc_0, nfors_0, &i_id_2, 0), _fx_catch_17);
            FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_121, 0), _fx_catch_17);
            FX_CALL(
               _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  &i_id_2, _fx_g19C_gen_code__CTypInt, &v_121, &_fx_g18C_gen_code__None2_, 0, &for_loc_0, block_stack_ref_0,
                  &v_122, 0), _fx_catch_17);
            FX_COPY_PTR(v_122.t0, &i_exp_4);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_4, i_exps_1, true, &v_123), _fx_catch_17);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(n_exp_1, n_exps_1, true, &v_124), _fx_catch_17);
            _fx_make_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(i_exp_4,
               v_123, v_124, init_checks_1, init_ccode_21, &v_107);

         _fx_catch_17: ;
            if (v_124) {
               _fx_free_LN14C_form__cexp_t(&v_124);
            }
            if (v_123) {
               _fx_free_LN14C_form__cexp_t(&v_123);
            }
            if (i_exp_4) {
               _fx_free_N14C_form__cexp_t(&i_exp_4);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_122);
            _fx_free_R16Ast__val_flags_t(&v_121);
            FX_FREE_STR(&v_120);
            if (init_ccode_21) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_21);
            }
            if (n_exp_1) {
               _fx_free_N14C_form__cexp_t(&n_exp_1);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_119);
            _fx_free_Nt6option1N14C_form__cexp_t(&v_118);
            _fx_free_R16Ast__val_flags_t(&v_117);

         _fx_endmatch_7: ;
            FX_CHECK_EXN(_fx_catch_18);
            FX_COPY_PTR(v_107.t0, &i_exp_3);
            FX_COPY_PTR(v_107.t1, &i_exps_4);
            FX_COPY_PTR(v_107.t2, &n_exps_4);
            FX_COPY_PTR(v_107.t3, &init_checks_4);
            FX_COPY_PTR(v_107.t4, &init_ccode_20);
            _fx_R9Ast__id_t v_126;
            fx_str_t slit_12 = FX_MAKE_STR("data");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_12, &v_126, 0), _fx_catch_18);
            FX_CALL(
               _fx_M6C_formFM14make_const_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(_fx_g23C_gen_code__CTypUniChar, &v_108, 0),
               _fx_catch_18);
            FX_CALL(
               _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(col_exp_1, &v_126, v_108,
                  &get_chars_0, 0), _fx_catch_18);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g23C_gen_code__CTypUniChar, &for_loc_0, &v_109);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g24C_gen_code__COpArrayElem, get_chars_0, i_exp_3, &v_109, &get_char_i_0), _fx_catch_18);
            FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_110, 0), _fx_catch_18);
            _fx_make_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&iter_val_i_1, get_char_i_0, &v_110, &v_111);
            FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_111, body_elems_1, true, &v_112),
               _fx_catch_18);
            _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
               0, i_exps_4, n_exps_4, for_checks_1, incr_exps_1, init_checks_4, init_ccode_20, pre_body_ccode_2, v_112,
               post_checks_3, &v_35);

         _fx_catch_18: ;
            if (v_112) {
               _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_112);
            }
            _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_111);
            _fx_free_R16Ast__val_flags_t(&v_110);
            if (get_char_i_0) {
               _fx_free_N14C_form__cexp_t(&get_char_i_0);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_109);
            if (get_chars_0) {
               _fx_free_N14C_form__cexp_t(&get_chars_0);
            }
            if (v_108) {
               _fx_free_N14C_form__ctyp_t(&v_108);
            }
            if (init_ccode_20) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_20);
            }
            if (init_checks_4) {
               _fx_free_LN14C_form__cexp_t(&init_checks_4);
            }
            if (n_exps_4) {
               _fx_free_LN14C_form__cexp_t(&n_exps_4);
            }
            if (i_exps_4) {
               _fx_free_LN14C_form__cexp_t(&i_exps_4);
            }
            if (i_exp_3) {
               _fx_free_N14C_form__cexp_t(&i_exp_3);
            }
            _fx_free_T5N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_107);
            if (calc_n_exp_1) {
               _fx_free_N14C_form__cexp_t(&calc_n_exp_1);
            }
            if (v_106) {
               _fx_free_LN14C_form__cexp_t(&v_106);
            }
         }
         else if (tag_3 == 17) {
            _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_127 = {0};
            _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___5 = {0};
            _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_128 = {0};
            _fx_LN14C_form__cexp_t i_exps_5 = 0;
            _fx_LN14C_form__cexp_t n_exps_5 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_22 = 0;
            _fx_LN14C_form__cexp_t v_129 = 0;
            _fx_LN14C_form__cexp_t v_130 = 0;
            _fx_LN14C_form__cexp_t __fold_result___6 = 0;
            _fx_LN14C_form__cexp_t init_checks_5 = 0;
            _fx_LN14C_form__cexp_t i_exps_6 = 0;
            _fx_LN14C_form__cexp_t n_exps_6 = 0;
            _fx_LN14C_form__cexp_t init_checks_6 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_23 = 0;
            _fx_N14C_form__ctyp_t c_et_1 = 0;
            _fx_N14C_form__ctyp_t c_et_ptr_0 = 0;
            _fx_LN14C_form__cexp_t rev_i_exps_0 = 0;
            _fx_N14C_form__cexp_t inner_idx_0 = 0;
            _fx_N14C_form__cexp_t v_131 = 0;
            _fx_LN14C_form__cexp_t v_132 = 0;
            _fx_LN14C_form__cexp_t v_133 = 0;
            _fx_LN14C_form__cexp_t slice_idxs_0 = 0;
            _fx_N14C_form__cexp_t v_134 = 0;
            _fx_LN14C_form__cexp_t v_135 = 0;
            _fx_N14C_form__cexp_t get_arr_slice_0 = 0;
            fx_str_t v_136 = {0};
            fx_str_t v_137 = {0};
            _fx_R16Ast__val_flags_t v_138 = {0};
            _fx_Nt6option1N14C_form__cexp_t v_139 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_140 = {0};
            _fx_N14C_form__cexp_t ptr_exp_0 = 0;
            _fx_LN15C_form__cstmt_t pre_body_ccode_4 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_141 = {0};
            _fx_N14C_form__cexp_t get_arr_elem_0 = 0;
            _fx_R16Ast__val_flags_t v_142 = {0};
            _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_143 = {0};
            _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_144 = 0;
            _fx_T2iN14K_form__ktyp_t* vcase_1 = &v_89->u.KTypArray;
            int_ ndims_1 = vcase_1->t0;
            if (n_exps_1 == 0) {
               _fx_make_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(0, 0, init_ccode_18, &__fold_result___5);
               for (int_ k_1 = 0; k_1 < ndims_1; k_1++) {
                  _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_145 = {0};
                  _fx_LN14C_form__cexp_t i_exps_7 = 0;
                  _fx_LN14C_form__cexp_t n_exps_7 = 0;
                  _fx_LN15C_form__cstmt_t init_ccode_24 = 0;
                  _fx_N14C_form__cexp_t v_146 = 0;
                  _fx_LN14C_form__cexp_t v_147 = 0;
                  _fx_N14C_form__cexp_t calc_n_exp_2 = 0;
                  fx_str_t iter_letter_0 = {0};
                  fx_str_t v_148 = {0};
                  _fx_R16Ast__val_flags_t v_149 = {0};
                  _fx_Nt6option1N14C_form__cexp_t v_150 = {0};
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_151 = {0};
                  _fx_N14C_form__cexp_t n_exp_2 = 0;
                  _fx_LN15C_form__cstmt_t init_ccode_25 = 0;
                  _fx_R16Ast__val_flags_t v_152 = {0};
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_153 = {0};
                  _fx_N14C_form__cexp_t i_exp_5 = 0;
                  _fx_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_154 = {0};
                  _fx_copy_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5, &v_145);
                  FX_COPY_PTR(v_145.t0, &i_exps_7);
                  FX_COPY_PTR(v_145.t1, &n_exps_7);
                  FX_COPY_PTR(v_145.t2, &init_ccode_24);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(k_1, &for_loc_0, &v_146, 0),
                     _fx_catch_19);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_146, 0, true, &v_147), _fx_catch_19);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(col_exp_1, v_147, false, &v_147), _fx_catch_19);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g23C_form__std_FX_ARR_SIZE, v_147, _fx_g19C_gen_code__CTypInt, &for_loc_0, &calc_n_exp_2, 0),
                     _fx_catch_19);
                  FX_CALL(_fx_M10C_gen_codeFM3nthS2LSi(for_letters_0, k_1 + dims_ofs_0, &iter_letter_0, 0), _fx_catch_19);
                  fx_str_t slit_13 = FX_MAKE_STR("n");
                  {
                     const fx_str_t strs_0[] = { slit_13, iter_letter_0 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_0, 2, &v_148), _fx_catch_19);
                  }
                  _fx_R9Ast__id_t v_155;
                  FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &v_148, &v_155, 0), _fx_catch_19);
                  FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_149, 0), _fx_catch_19);
                  _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(calc_n_exp_2, &v_150);
                  FX_CALL(
                     _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                        &v_155, _fx_g19C_gen_code__CTypInt, &v_149, &v_150, init_ccode_24, &for_loc_0, block_stack_ref_0,
                        &v_151, 0), _fx_catch_19);
                  FX_COPY_PTR(v_151.t0, &n_exp_2);
                  FX_COPY_PTR(v_151.t1, &init_ccode_25);
                  _fx_R9Ast__id_t i_id_3;
                  FX_CALL(
                     _fx_M10C_gen_codeFM11get_iter_idR9Ast__id_t7iLR9Ast__id_tSiiR10Ast__loc_ti(k_1, at_ids_1, &iter_letter_0,
                        for_idx_0, km_idx_0, loc_0, nfors_0, &i_id_3, 0), _fx_catch_19);
                  FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_152, 0), _fx_catch_19);
                  FX_CALL(
                     _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                        &i_id_3, _fx_g19C_gen_code__CTypInt, &v_152, &_fx_g18C_gen_code__None2_, 0, &for_loc_0,
                        block_stack_ref_0, &v_153, 0), _fx_catch_19);
                  FX_COPY_PTR(v_153.t0, &i_exp_5);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_5, i_exps_7, false, &i_exps_7), _fx_catch_19);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(n_exp_2, n_exps_7, false, &n_exps_7), _fx_catch_19);
                  _fx_make_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(i_exps_7, n_exps_7, init_ccode_25, &v_154);
                  _fx_free_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5);
                  _fx_copy_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_154, &__fold_result___5);

               _fx_catch_19: ;
                  _fx_free_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_154);
                  if (i_exp_5) {
                     _fx_free_N14C_form__cexp_t(&i_exp_5);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_153);
                  _fx_free_R16Ast__val_flags_t(&v_152);
                  if (init_ccode_25) {
                     _fx_free_LN15C_form__cstmt_t(&init_ccode_25);
                  }
                  if (n_exp_2) {
                     _fx_free_N14C_form__cexp_t(&n_exp_2);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_151);
                  _fx_free_Nt6option1N14C_form__cexp_t(&v_150);
                  _fx_free_R16Ast__val_flags_t(&v_149);
                  FX_FREE_STR(&v_148);
                  FX_FREE_STR(&iter_letter_0);
                  if (calc_n_exp_2) {
                     _fx_free_N14C_form__cexp_t(&calc_n_exp_2);
                  }
                  if (v_147) {
                     _fx_free_LN14C_form__cexp_t(&v_147);
                  }
                  if (v_146) {
                     _fx_free_N14C_form__cexp_t(&v_146);
                  }
                  if (init_ccode_24) {
                     _fx_free_LN15C_form__cstmt_t(&init_ccode_24);
                  }
                  if (n_exps_7) {
                     _fx_free_LN14C_form__cexp_t(&n_exps_7);
                  }
                  if (i_exps_7) {
                     _fx_free_LN14C_form__cexp_t(&i_exps_7);
                  }
                  _fx_free_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_145);
                  FX_CHECK_EXN(_fx_catch_21);
               }
               _fx_copy_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5, &v_128);
               FX_COPY_PTR(v_128.t0, &i_exps_5);
               FX_COPY_PTR(v_128.t1, &n_exps_5);
               FX_COPY_PTR(v_128.t2, &init_ccode_22);
               FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(i_exps_5, &v_129, 0), _fx_catch_21);
               FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(n_exps_5, &v_130, 0), _fx_catch_21);
               _fx_make_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(v_129, v_130, init_checks_1,
                  init_ccode_22, &v_127);
            }
            else {
               FX_COPY_PTR(init_checks_1, &__fold_result___6);
               int_ k_2 = 0;
               _fx_LN14C_form__cexp_t lst_3 = n_exps_1;
               for (; lst_3; lst_3 = lst_3->tl, k_2 += 1) {
                  _fx_LN14C_form__cexp_t init_checks_7 = 0;
                  _fx_N14C_form__cexp_t v_156 = 0;
                  _fx_LN14C_form__cexp_t v_157 = 0;
                  _fx_N14C_form__cexp_t calc_n_exp_3 = 0;
                  _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_158 = {0};
                  _fx_N14C_form__cexp_t init_check_k_0 = 0;
                  _fx_N14C_form__cexp_t prev_nk_0 = lst_3->hd;
                  FX_COPY_PTR(__fold_result___6, &init_checks_7);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(k_2, &for_loc_0, &v_156, 0),
                     _fx_catch_20);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_156, 0, true, &v_157), _fx_catch_20);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(col_exp_1, v_157, false, &v_157), _fx_catch_20);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g23C_form__std_FX_ARR_SIZE, v_157, _fx_g19C_gen_code__CTypInt, &for_loc_0, &calc_n_exp_3, 0),
                     _fx_catch_20);
                  _fx_N17C_form__cbinary_t v_159;
                  _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_159);
                  _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &for_loc_0, &v_158);
                  FX_CALL(
                     _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                        &v_159, prev_nk_0, calc_n_exp_3, &v_158, &init_check_k_0), _fx_catch_20);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(init_check_k_0, init_checks_7, false, &init_checks_7), _fx_catch_20);
                  _fx_free_LN14C_form__cexp_t(&__fold_result___6);
                  FX_COPY_PTR(init_checks_7, &__fold_result___6);

               _fx_catch_20: ;
                  if (init_check_k_0) {
                     _fx_free_N14C_form__cexp_t(&init_check_k_0);
                  }
                  _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_158);
                  if (calc_n_exp_3) {
                     _fx_free_N14C_form__cexp_t(&calc_n_exp_3);
                  }
                  if (v_157) {
                     _fx_free_LN14C_form__cexp_t(&v_157);
                  }
                  if (v_156) {
                     _fx_free_N14C_form__cexp_t(&v_156);
                  }
                  if (init_checks_7) {
                     _fx_free_LN14C_form__cexp_t(&init_checks_7);
                  }
                  FX_CHECK_EXN(_fx_catch_21);
               }
               FX_COPY_PTR(__fold_result___6, &init_checks_5);
               _fx_make_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(i_exps_1, n_exps_1,
                  init_checks_5, init_ccode_18, &v_127);
            }
            FX_COPY_PTR(v_127.t0, &i_exps_6);
            FX_COPY_PTR(v_127.t1, &n_exps_6);
            FX_COPY_PTR(v_127.t2, &init_checks_6);
            FX_COPY_PTR(v_127.t3, &init_ccode_23);
            FX_CALL(
               _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(vcase_1->t1, &for_loc_0, &c_et_1,
                  0), _fx_catch_21);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(c_et_1, &c_et_ptr_0, 0), _fx_catch_21);
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(i_exps_6, &rev_i_exps_0, 0), _fx_catch_21);
            FX_CALL(_fx_M10C_gen_codeFM2hdN14C_form__cexp_t1LN14C_form__cexp_t(rev_i_exps_0, &inner_idx_0, 0), _fx_catch_21);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &for_loc_0, &v_131, 0), _fx_catch_21);
            FX_CALL(_fx_M10C_gen_codeFM2tlLN14C_form__cexp_t1LN14C_form__cexp_t(rev_i_exps_0, &v_132, 0), _fx_catch_21);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_131, v_132, true, &v_133), _fx_catch_21);
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(v_133, &slice_idxs_0, 0), _fx_catch_21);
            _fx_R9Ast__id_t v_160;
            FX_CALL(_fx_M10C_gen_codeFM3nthR9Ast__id_t2LR9Ast__id_ti(_fx_g21C_form__std_FX_PTR_xD, ndims_1 - 1, &v_160, 0),
               _fx_catch_21);
            FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(c_et_1, &for_loc_0, &v_134),
               _fx_catch_21);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(col_exp_1, slice_idxs_0, true, &v_135), _fx_catch_21);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_134, v_135, false, &v_135), _fx_catch_21);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_160,
                  v_135, c_et_ptr_0, &for_loc_0, &get_arr_slice_0, 0), _fx_catch_21);
            FX_CALL(_fx_M3AstFM2ppS1RM4id_t(&col__0, &v_136, 0), _fx_catch_21);
            fx_str_t slit_14 = FX_MAKE_STR("ptr_");
            {
               const fx_str_t strs_1[] = { slit_14, v_136 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_1, 2, &v_137), _fx_catch_21);
            }
            _fx_R9Ast__id_t ptr_id_0;
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &v_137, &ptr_id_0, 0), _fx_catch_21);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_138, 0), _fx_catch_21);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(get_arr_slice_0, &v_139);
            fx_str_t slit_15 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &ptr_id_0, c_et_ptr_0, &v_138, &slit_15, &v_139, pre_body_ccode_2, &for_loc_0, &v_140, 0), _fx_catch_21);
            FX_COPY_PTR(v_140.t0, &ptr_exp_0);
            FX_COPY_PTR(v_140.t1, &pre_body_ccode_4);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(c_et_1, &for_loc_0, &v_141);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g24C_gen_code__COpArrayElem, ptr_exp_0, inner_idx_0, &v_141, &get_arr_elem_0), _fx_catch_21);
            FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_142, 0), _fx_catch_21);
            _fx_make_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&iter_val_i_1, get_arr_elem_0, &v_142, &v_143);
            FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_143, body_elems_1, true, &v_144),
               _fx_catch_21);
            _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
               0, i_exps_6, n_exps_6, for_checks_1, incr_exps_1, init_checks_6, init_ccode_23, pre_body_ccode_4, v_144,
               post_checks_3, &v_35);

         _fx_catch_21: ;
            if (v_144) {
               _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_144);
            }
            _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_143);
            _fx_free_R16Ast__val_flags_t(&v_142);
            if (get_arr_elem_0) {
               _fx_free_N14C_form__cexp_t(&get_arr_elem_0);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_141);
            if (pre_body_ccode_4) {
               _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_4);
            }
            if (ptr_exp_0) {
               _fx_free_N14C_form__cexp_t(&ptr_exp_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_140);
            _fx_free_Nt6option1N14C_form__cexp_t(&v_139);
            _fx_free_R16Ast__val_flags_t(&v_138);
            FX_FREE_STR(&v_137);
            FX_FREE_STR(&v_136);
            if (get_arr_slice_0) {
               _fx_free_N14C_form__cexp_t(&get_arr_slice_0);
            }
            if (v_135) {
               _fx_free_LN14C_form__cexp_t(&v_135);
            }
            if (v_134) {
               _fx_free_N14C_form__cexp_t(&v_134);
            }
            if (slice_idxs_0) {
               _fx_free_LN14C_form__cexp_t(&slice_idxs_0);
            }
            if (v_133) {
               _fx_free_LN14C_form__cexp_t(&v_133);
            }
            if (v_132) {
               _fx_free_LN14C_form__cexp_t(&v_132);
            }
            if (v_131) {
               _fx_free_N14C_form__cexp_t(&v_131);
            }
            if (inner_idx_0) {
               _fx_free_N14C_form__cexp_t(&inner_idx_0);
            }
            if (rev_i_exps_0) {
               _fx_free_LN14C_form__cexp_t(&rev_i_exps_0);
            }
            if (c_et_ptr_0) {
               _fx_free_N14C_form__ctyp_t(&c_et_ptr_0);
            }
            if (c_et_1) {
               _fx_free_N14C_form__ctyp_t(&c_et_1);
            }
            if (init_ccode_23) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_23);
            }
            if (init_checks_6) {
               _fx_free_LN14C_form__cexp_t(&init_checks_6);
            }
            if (n_exps_6) {
               _fx_free_LN14C_form__cexp_t(&n_exps_6);
            }
            if (i_exps_6) {
               _fx_free_LN14C_form__cexp_t(&i_exps_6);
            }
            if (init_checks_5) {
               _fx_free_LN14C_form__cexp_t(&init_checks_5);
            }
            if (__fold_result___6) {
               _fx_free_LN14C_form__cexp_t(&__fold_result___6);
            }
            if (v_130) {
               _fx_free_LN14C_form__cexp_t(&v_130);
            }
            if (v_129) {
               _fx_free_LN14C_form__cexp_t(&v_129);
            }
            if (init_ccode_22) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_22);
            }
            if (n_exps_5) {
               _fx_free_LN14C_form__cexp_t(&n_exps_5);
            }
            if (i_exps_5) {
               _fx_free_LN14C_form__cexp_t(&i_exps_5);
            }
            _fx_free_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_128);
            _fx_free_T3LN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5);
            _fx_free_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_127);
         }
         else if (tag_3 == 18) {
            _fx_LN14C_form__cexp_t v_161 = 0;
            _fx_N14C_form__cexp_t calc_n_exp_4 = 0;
            _fx_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_162 = {0};
            _fx_R16Ast__val_flags_t v_163 = {0};
            _fx_Nt6option1N14C_form__cexp_t v_164 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_165 = {0};
            _fx_N14C_form__cexp_t n_exp_3 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_26 = 0;
            fx_str_t v_166 = {0};
            _fx_R16Ast__val_flags_t v_167 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_168 = {0};
            _fx_N14C_form__cexp_t i_exp_6 = 0;
            _fx_LN14C_form__cexp_t v_169 = 0;
            _fx_LN14C_form__cexp_t v_170 = 0;
            _fx_N14C_form__cexp_t prev_n_0 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_171 = {0};
            _fx_N14C_form__cexp_t init_check_0 = 0;
            _fx_LN14C_form__cexp_t v_172 = 0;
            _fx_LN14C_form__cexp_t i_exps_8 = 0;
            _fx_LN14C_form__cexp_t n_exps_8 = 0;
            _fx_LN14C_form__cexp_t init_checks_8 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_27 = 0;
            _fx_N14C_form__ctyp_t c_et_2 = 0;
            _fx_N14C_form__ctyp_t c_et_ptr_1 = 0;
            fx_str_t colname_0 = {0};
            fx_str_t v_173 = {0};
            _fx_N14C_form__cexp_t c_et_exp_0 = 0;
            _fx_N14C_form__ctyp_t v_174 = 0;
            _fx_R16Ast__val_flags_t v_175 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_176 = {0};
            _fx_N14C_form__cexp_t iter_exp_0 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_28 = 0;
            _fx_LN14C_form__cexp_t v_177 = 0;
            _fx_N14C_form__cexp_t start_read_exp_0 = 0;
            fx_str_t v_178 = {0};
            _fx_R16Ast__val_flags_t v_179 = {0};
            _fx_Nt6option1N14C_form__cexp_t v_180 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_181 = {0};
            _fx_N14C_form__cexp_t ptr_exp_1 = 0;
            _fx_LN15C_form__cstmt_t init_ccode_29 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_182 = {0};
            _fx_N14C_form__cexp_t get_vec_elem_0 = 0;
            _fx_LN14C_form__cexp_t v_183 = 0;
            _fx_N14C_form__cexp_t incr_call_exp_0 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_184 = {0};
            _fx_N14C_form__cexp_t incr_exp_0 = 0;
            _fx_R16Ast__val_flags_t elem_flags_0 = {0};
            _fx_LN14C_form__cexp_t v_185 = 0;
            _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_186 = {0};
            _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t v_187 = 0;
            _fx_N14K_form__ktyp_t et_1 = v_89->u.KTypVector;
            _fx_R9Ast__id_t v_188;
            fx_str_t slit_16 = FX_MAKE_STR("FX_RRB_SIZE");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_16, &v_188, 0), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(col_exp_1, 0, true, &v_161), _fx_catch_22);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_188,
                  v_161, _fx_g19C_gen_code__CTypInt, &for_loc_0, &calc_n_exp_4, 0), _fx_catch_22);
            if (n_exps_1 == 0) {
               _fx_R9Ast__id_t v_189;
               fx_str_t slit_17 = FX_MAKE_STR("n");
               FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_17, &v_189, 0), _fx_catch_22);
               FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_163, 0), _fx_catch_22);
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(calc_n_exp_4, &v_164);
               FX_CALL(
                  _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     &v_189, _fx_g19C_gen_code__CTypInt, &v_163, &v_164, init_ccode_18, &for_loc_0, block_stack_ref_0, &v_165,
                     0), _fx_catch_22);
               FX_COPY_PTR(v_165.t0, &n_exp_3);
               FX_COPY_PTR(v_165.t1, &init_ccode_26);
               FX_CALL(_fx_M10C_gen_codeFM3nthS2LSi(for_letters_0, dims_ofs_0, &v_166, 0), _fx_catch_22);
               _fx_R9Ast__id_t i_id_4;
               FX_CALL(
                  _fx_M10C_gen_codeFM11get_iter_idR9Ast__id_t7iLR9Ast__id_tSiiR10Ast__loc_ti(0, at_ids_1, &v_166, for_idx_0,
                     km_idx_0, loc_0, nfors_0, &i_id_4, 0), _fx_catch_22);
               FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_167, 0), _fx_catch_22);
               FX_CALL(
                  _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     &i_id_4, _fx_g19C_gen_code__CTypInt, &v_167, &_fx_g18C_gen_code__None2_, 0, &for_loc_0, block_stack_ref_0,
                     &v_168, 0), _fx_catch_22);
               FX_COPY_PTR(v_168.t0, &i_exp_6);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_6, i_exps_1, true, &v_169), _fx_catch_22);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(n_exp_3, n_exps_1, true, &v_170), _fx_catch_22);
               _fx_make_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(v_169, v_170, init_checks_1,
                  init_ccode_26, &v_162);
            }
            else {
               FX_CALL(_fx_M10C_gen_codeFM2hdN14C_form__cexp_t1LN14C_form__cexp_t(n_exps_1, &prev_n_0, 0), _fx_catch_22);
               _fx_N17C_form__cbinary_t v_190;
               _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_190);
               _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &for_loc_0, &v_171);
               FX_CALL(
                  _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                     &v_190, prev_n_0, calc_n_exp_4, &v_171, &init_check_0), _fx_catch_22);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(init_check_0, init_checks_1, true, &v_172), _fx_catch_22);
               _fx_make_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(i_exps_1, n_exps_1, v_172,
                  init_ccode_18, &v_162);
            }
            FX_COPY_PTR(v_162.t0, &i_exps_8);
            FX_COPY_PTR(v_162.t1, &n_exps_8);
            FX_COPY_PTR(v_162.t2, &init_checks_8);
            FX_COPY_PTR(v_162.t3, &init_ccode_27);
            FX_CALL(
               _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(et_1, &for_loc_0, &c_et_2, 0),
               _fx_catch_22);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(c_et_2, &c_et_ptr_1, 0), _fx_catch_22);
            FX_CALL(_fx_M3AstFM2ppS1RM4id_t(&col__0, &colname_0, 0), _fx_catch_22);
            fx_str_t slit_18 = FX_MAKE_STR("iter_");
            {
               const fx_str_t strs_2[] = { slit_18, colname_0 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_2, 2, &v_173), _fx_catch_22);
            }
            _fx_R9Ast__id_t iter_id_0;
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &v_173, &iter_id_0, 0), _fx_catch_22);
            FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(c_et_2, &for_loc_0, &c_et_exp_0),
               _fx_catch_22);
            _fx_R9Ast__id_t v_191;
            fx_str_t slit_19 = FX_MAKE_STR("fx_rrbiter_t");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_19, &v_191, 0), _fx_catch_22);
            FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&v_191, &v_174), _fx_catch_22);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_175, 0), _fx_catch_22);
            fx_str_t slit_20 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &iter_id_0, v_174, &v_175, &slit_20, &_fx_g18C_gen_code__None2_, init_ccode_27, &for_loc_0, &v_176, 0),
               _fx_catch_22);
            FX_COPY_PTR(v_176.t0, &iter_exp_0);
            FX_COPY_PTR(v_176.t1, &init_ccode_28);
            _fx_R9Ast__id_t v_192;
            fx_str_t slit_21 = FX_MAKE_STR("FX_RRB_START_READ");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_21, &v_192, 0), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(iter_exp_0, 0, true, &v_177), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(col_exp_1, v_177, false, &v_177), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(c_et_exp_0, v_177, false, &v_177), _fx_catch_22);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_192,
                  v_177, _fx_g23C_form__std_CTypVoidPtr, &for_loc_0, &start_read_exp_0, 0), _fx_catch_22);
            fx_str_t slit_22 = FX_MAKE_STR("ptr_");
            {
               const fx_str_t strs_3[] = { slit_22, colname_0 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_3, 2, &v_178), _fx_catch_22);
            }
            _fx_R9Ast__id_t ptr_id_1;
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &v_178, &ptr_id_1, 0), _fx_catch_22);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_179, 0), _fx_catch_22);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(start_read_exp_0, &v_180);
            fx_str_t slit_23 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &ptr_id_1, c_et_ptr_1, &v_179, &slit_23, &v_180, init_ccode_28, &for_loc_0, &v_181, 0), _fx_catch_22);
            FX_COPY_PTR(v_181.t0, &ptr_exp_1);
            FX_COPY_PTR(v_181.t1, &init_ccode_29);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(c_et_2, &for_loc_0, &v_182);
            FX_CALL(
               _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g20C_gen_code__COpDeref, ptr_exp_1, &v_182, &get_vec_elem_0), _fx_catch_22);
            _fx_R9Ast__id_t v_193;
            fx_str_t slit_24 = FX_MAKE_STR("FX_RRB_NEXT");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_24, &v_193, 0), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ptr_exp_1, 0, true, &v_183), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(iter_exp_0, v_183, false, &v_183), _fx_catch_22);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(c_et_exp_0, v_183, false, &v_183), _fx_catch_22);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_193,
                  v_183, _fx_g23C_form__std_CTypVoidPtr, &for_loc_0, &incr_call_exp_0, 0), _fx_catch_22);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypVoid, &for_loc_0, &v_184);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g21C_gen_code__COpAssign, ptr_exp_1, incr_call_exp_0, &v_184, &incr_exp_0), _fx_catch_22);
            bool res_4;
            FX_CALL(_fx_M6K_formFM14is_ktyp_scalarB1N14K_form__ktyp_t(et_1, &res_4, 0), _fx_catch_22);
            if (res_4) {
               FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&elem_flags_0, 0), _fx_catch_22);
            }
            else {
               FX_CALL(_fx_M3AstFM21default_tempref_flagsRM11val_flags_t0(&elem_flags_0, 0), _fx_catch_22);
            }
            FX_CALL(_fx_cons_LN14C_form__cexp_t(incr_exp_0, incr_exps_1, true, &v_185), _fx_catch_22);
            _fx_make_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&iter_val_i_1, get_vec_elem_0, &elem_flags_0, &v_186);
            FX_CALL(_fx_cons_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_186, body_elems_1, true, &v_187),
               _fx_catch_22);
            _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
               0, i_exps_8, n_exps_8, for_checks_1, v_185, init_checks_8, init_ccode_29, pre_body_ccode_2, v_187, post_checks_3,
               &v_35);

         _fx_catch_22: ;
            if (v_187) {
               _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_187);
            }
            _fx_free_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&v_186);
            if (v_185) {
               _fx_free_LN14C_form__cexp_t(&v_185);
            }
            _fx_free_R16Ast__val_flags_t(&elem_flags_0);
            if (incr_exp_0) {
               _fx_free_N14C_form__cexp_t(&incr_exp_0);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_184);
            if (incr_call_exp_0) {
               _fx_free_N14C_form__cexp_t(&incr_call_exp_0);
            }
            if (v_183) {
               _fx_free_LN14C_form__cexp_t(&v_183);
            }
            if (get_vec_elem_0) {
               _fx_free_N14C_form__cexp_t(&get_vec_elem_0);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_182);
            if (init_ccode_29) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_29);
            }
            if (ptr_exp_1) {
               _fx_free_N14C_form__cexp_t(&ptr_exp_1);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_181);
            _fx_free_Nt6option1N14C_form__cexp_t(&v_180);
            _fx_free_R16Ast__val_flags_t(&v_179);
            FX_FREE_STR(&v_178);
            if (start_read_exp_0) {
               _fx_free_N14C_form__cexp_t(&start_read_exp_0);
            }
            if (v_177) {
               _fx_free_LN14C_form__cexp_t(&v_177);
            }
            if (init_ccode_28) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_28);
            }
            if (iter_exp_0) {
               _fx_free_N14C_form__cexp_t(&iter_exp_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_176);
            _fx_free_R16Ast__val_flags_t(&v_175);
            if (v_174) {
               _fx_free_N14C_form__ctyp_t(&v_174);
            }
            if (c_et_exp_0) {
               _fx_free_N14C_form__cexp_t(&c_et_exp_0);
            }
            FX_FREE_STR(&v_173);
            FX_FREE_STR(&colname_0);
            if (c_et_ptr_1) {
               _fx_free_N14C_form__ctyp_t(&c_et_ptr_1);
            }
            if (c_et_2) {
               _fx_free_N14C_form__ctyp_t(&c_et_2);
            }
            if (init_ccode_27) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_27);
            }
            if (init_checks_8) {
               _fx_free_LN14C_form__cexp_t(&init_checks_8);
            }
            if (n_exps_8) {
               _fx_free_LN14C_form__cexp_t(&n_exps_8);
            }
            if (i_exps_8) {
               _fx_free_LN14C_form__cexp_t(&i_exps_8);
            }
            if (v_172) {
               _fx_free_LN14C_form__cexp_t(&v_172);
            }
            if (init_check_0) {
               _fx_free_N14C_form__cexp_t(&init_check_0);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_171);
            if (prev_n_0) {
               _fx_free_N14C_form__cexp_t(&prev_n_0);
            }
            if (v_170) {
               _fx_free_LN14C_form__cexp_t(&v_170);
            }
            if (v_169) {
               _fx_free_LN14C_form__cexp_t(&v_169);
            }
            if (i_exp_6) {
               _fx_free_N14C_form__cexp_t(&i_exp_6);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_168);
            _fx_free_R16Ast__val_flags_t(&v_167);
            FX_FREE_STR(&v_166);
            if (init_ccode_26) {
               _fx_free_LN15C_form__cstmt_t(&init_ccode_26);
            }
            if (n_exp_3) {
               _fx_free_N14C_form__cexp_t(&n_exp_3);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_165);
            _fx_free_Nt6option1N14C_form__cexp_t(&v_164);
            _fx_free_R16Ast__val_flags_t(&v_163);
            _fx_free_T4LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_162);
            if (calc_n_exp_4) {
               _fx_free_N14C_form__cexp_t(&calc_n_exp_4);
            }
            if (v_161) {
               _fx_free_LN14C_form__cexp_t(&v_161);
            }
         }
         else {
            fx_str_t v_194 = {0};
            fx_str_t v_195 = {0};
            fx_str_t v_196 = {0};
            fx_str_t v_197 = {0};
            fx_str_t v_198 = {0};
            fx_exn_t v_199 = {0};
            FX_CALL(_fx_M6K_formFM8atom2strS1N14K_form__atom_t(a_1, &v_194, 0), _fx_catch_23);
            FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_194, &v_195, 0), _fx_catch_23);
            FX_CALL(_fx_M6K_formFM6stringS1N14K_form__ktyp_t(ktyp_0, &v_196, 0), _fx_catch_23);
            fx_str_t slit_25 = FX_MAKE_STR("cannot iterate over \'");
            fx_str_t slit_26 = FX_MAKE_STR("\' of type \'");
            fx_str_t slit_27 = FX_MAKE_STR("\'; it needs to be array, list, vector or string");
            {
               const fx_str_t strs_4[] = { slit_25, v_195, slit_26, v_196, slit_27 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_4, 5, &v_197), _fx_catch_23);
            }
            FX_CALL(_fx_M10C_gen_codeFM11for_err_msgS4iiiS(for_idx_0, nfors_0, k_0, &v_197, &v_198, 0), _fx_catch_23);
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&for_loc_0, &v_198, &v_199, 0), _fx_catch_23);
            FX_THROW(&v_199, false, _fx_catch_23);

         _fx_catch_23: ;
            fx_free_exn(&v_199);
            FX_FREE_STR(&v_198);
            FX_FREE_STR(&v_197);
            FX_FREE_STR(&v_196);
            FX_FREE_STR(&v_195);
            FX_FREE_STR(&v_194);
         }
         FX_CHECK_EXN(_fx_catch_24);

      _fx_catch_24: ;
         if (v_89) {
            _fx_free_N14K_form__ktyp_t(&v_89);
         }
         if (init_ccode_18) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_18);
         }
         if (col_exp_1) {
            _fx_free_N14C_form__cexp_t(&col_exp_1);
         }
         if (init_ccode_17) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_17);
         }
         if (init_ccode_16) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_16);
         }
         if (col_exp_0) {
            _fx_free_N14C_form__cexp_t(&col_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_88);
         FX_FREE_STR(&v_87);
         if (v_86) {
            _fx_free_rNt6option1N14C_form__cexp_t(&v_86);
         }
         if (init_ccode_15) {
            _fx_free_LN15C_form__cstmt_t(&init_ccode_15);
         }
         if (src_exp_0) {
            _fx_free_N14C_form__cexp_t(&src_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_85);
         _fx_free_N14K_form__atom_t(&v_84);
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_83);
         if (ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&ctyp_0);
         }
         if (ktyp_0) {
            _fx_free_N14K_form__ktyp_t(&ktyp_0);
         }
      }
      else {
         fx_str_t v_200 = {0};
         fx_exn_t v_201 = {0};
         fx_str_t slit_28 = FX_MAKE_STR("unsupported type of the for loop iteration domain");
         FX_CALL(_fx_M10C_gen_codeFM11for_err_msgS4iiiS(for_idx_0, nfors_0, k_0, &slit_28, &v_200, 0), _fx_catch_25);
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&for_loc_0, &v_200, &v_201, 0), _fx_catch_25);
         FX_THROW(&v_201, false, _fx_catch_25);

      _fx_catch_25: ;
         fx_free_exn(&v_201);
         FX_FREE_STR(&v_200);
      }
      FX_CHECK_EXN(_fx_catch_26);
      FX_COPY_PTR(v_35.t0, &lists_i_0);
      FX_COPY_PTR(v_35.t1, &i_exps_2);
      FX_COPY_PTR(v_35.t2, &n_exps_2);
      FX_COPY_PTR(v_35.t3, &for_checks_2);
      FX_COPY_PTR(v_35.t4, &incr_exps_2);
      FX_COPY_PTR(v_35.t5, &init_checks_2);
      FX_COPY_PTR(v_35.t6, &init_ccode_5);
      FX_COPY_PTR(v_35.t7, &pre_body_ccode_3);
      FX_COPY_PTR(v_35.t8, &body_elems_2);
      FX_COPY_PTR(v_35.t9, &post_checks_4);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(lists_i_0, list_exps_1, &v_36, 0),
         _fx_catch_26);
      _fx_make_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         v_36, i_exps_2, n_exps_2, for_checks_2, incr_exps_2, init_checks_2, init_ccode_5, pre_body_ccode_3, body_elems_2,
         post_checks_4, &v_37);
      _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         &__fold_result___0);
      _fx_copy_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         &v_37, &__fold_result___0);

   _fx_catch_26: ;
      _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         &v_37);
      if (v_36) {
         _fx_free_LN14C_form__cexp_t(&v_36);
      }
      if (post_checks_4) {
         _fx_free_LN14C_form__cexp_t(&post_checks_4);
      }
      if (body_elems_2) {
         _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&body_elems_2);
      }
      if (pre_body_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_3);
      }
      if (init_ccode_5) {
         _fx_free_LN15C_form__cstmt_t(&init_ccode_5);
      }
      if (init_checks_2) {
         _fx_free_LN14C_form__cexp_t(&init_checks_2);
      }
      if (incr_exps_2) {
         _fx_free_LN14C_form__cexp_t(&incr_exps_2);
      }
      if (for_checks_2) {
         _fx_free_LN14C_form__cexp_t(&for_checks_2);
      }
      if (n_exps_2) {
         _fx_free_LN14C_form__cexp_t(&n_exps_2);
      }
      if (i_exps_2) {
         _fx_free_LN14C_form__cexp_t(&i_exps_2);
      }
      if (lists_i_0) {
         _fx_free_LN14C_form__cexp_t(&lists_i_0);
      }
      _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         &v_35);
      if (post_checks_3) {
         _fx_free_LN14C_form__cexp_t(&post_checks_3);
      }
      if (body_elems_1) {
         _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&body_elems_1);
      }
      if (pre_body_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_2);
      }
      if (init_ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&init_ccode_4);
      }
      if (init_checks_1) {
         _fx_free_LN14C_form__cexp_t(&init_checks_1);
      }
      if (incr_exps_1) {
         _fx_free_LN14C_form__cexp_t(&incr_exps_1);
      }
      if (for_checks_1) {
         _fx_free_LN14C_form__cexp_t(&for_checks_1);
      }
      if (n_exps_1) {
         _fx_free_LN14C_form__cexp_t(&n_exps_1);
      }
      if (i_exps_1) {
         _fx_free_LN14C_form__cexp_t(&i_exps_1);
      }
      if (list_exps_1) {
         _fx_free_LN14C_form__cexp_t(&list_exps_1);
      }
      _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
         &v_34);
      _fx_free_N13K_form__dom_t(&dom_i_1);
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
      &__fold_result___0, &v_3);
   FX_COPY_PTR(v_3.t0, &list_exps_0);
   FX_COPY_PTR(v_3.t1, &i_exps_0);
   FX_COPY_PTR(v_3.t2, &n_exps_0);
   FX_COPY_PTR(v_3.t3, &for_checks_0);
   FX_COPY_PTR(v_3.t4, &incr_exps_0);
   FX_COPY_PTR(v_3.t5, &init_checks_0);
   FX_COPY_PTR(v_3.t6, &init_ccode_1);
   FX_COPY_PTR(v_3.t7, &pre_body_ccode_0);
   FX_COPY_PTR(v_3.t8, &body_elems_0);
   FX_COPY_PTR(v_3.t9, &post_checks_0);
   FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(init_checks_0, &v_4, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM17add_size_eq_checkLN15C_form__cstmt_t4LN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
         v_4, init_ccode_1, lbl_0, &for_loc_0, &init_ccode_2, 0), _fx_cleanup);
   if (ndims_0 > 1) {
      _fx_make_Ta2LN15C_form__cstmt_t(init_ccode_2, pre_body_ccode_0, &v_5);
   }
   else {
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(pre_body_ccode_0, init_ccode_2,
            &v_6, 0), _fx_cleanup);
      _fx_make_Ta2LN15C_form__cstmt_t(v_6, 0, &v_5);
   }
   FX_COPY_PTR(v_5.t0, &init_ccode_3);
   FX_COPY_PTR(v_5.t1, &pre_body_ccode_1);
   FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(post_checks_0, &post_checks_1, 0), _fx_cleanup);
   bool t_0;
   if (post_checks_1 != 0) {
      t_0 = i_exps_0 != 0;
   }
   else {
      t_0 = false;
   }
   if (t_0) {
      _fx_N17C_form__cbinary_t v_202;
      _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_202);
      FX_CALL(_fx_M10C_gen_codeFM2hdN14C_form__cexp_t1LN14C_form__cexp_t(i_exps_0, &v_7, 0), _fx_cleanup);
      FX_CALL(_fx_M10C_gen_codeFM2hdN14C_form__cexp_t1LN14C_form__cexp_t(n_exps_0, &v_8, 0), _fx_cleanup);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &end_for_loc_0, &v_9);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &v_202, v_7, v_8, &v_9, &v_10), _fx_cleanup);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(v_10, post_checks_1, true, &post_checks_2), _fx_cleanup);
   }
   else {
      int_ v_203;
      FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(post_checks_1, &v_203, 0), _fx_cleanup);
      if (v_203 > 1) {
         FX_COPY_PTR(post_checks_1, &post_checks_2);
      }
   }
   FX_CALL(
      _fx_M10C_gen_codeFM19add_size_post_checkLN15C_form__cstmt_t5LN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
         post_checks_2, 0, lbl_0, &end_for_loc_0, km_idx_0, &post_ccode_0, 0), _fx_cleanup);
   _fx_make_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(0, 0,
      &__fold_result___1);
   _fx_LN14C_form__cexp_t lst_4 = i_exps_0;
   _fx_LN14C_form__cexp_t lst_5 = n_exps_0;
   for (; lst_4 && lst_5; lst_5 = lst_5->tl, lst_4 = lst_4->tl) {
      _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_204 = {0};
      _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t for_headers_2 = 0;
      _fx_N14C_form__cexp_t v_205 = 0;
      _fx_N14C_form__cexp_t v_206 = 0;
      _fx_LN14C_form__cexp_t init_exps_0 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_207 = {0};
      _fx_N14C_form__cexp_t check_exp_0 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_208 = {0};
      _fx_N14C_form__cexp_t v_209 = 0;
      _fx_LN14C_form__cexp_t incr_exps_i_0 = 0;
      _fx_T2N14C_form__cexp_tLN14C_form__cexp_t v_210 = {0};
      _fx_N14C_form__cexp_t __fold_result___7 = 0;
      _fx_LN14C_form__cexp_t v_211 = 0;
      _fx_N14C_form__cexp_t check_exp_1 = 0;
      _fx_LN14C_form__cexp_t v_212 = 0;
      _fx_LN14C_form__cexp_t v_213 = 0;
      _fx_N14C_form__cexp_t check_exp_2 = 0;
      _fx_LN14C_form__cexp_t incr_exps_i_1 = 0;
      _fx_Nt6option1N14C_form__ctyp_t v_214 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_215 = {0};
      _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_216 = {0};
      _fx_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_217 = {0};
      _fx_N14C_form__cexp_t n_exp_4 = lst_5->hd;
      _fx_N14C_form__cexp_t i_exp_7 = lst_4->hd;
      _fx_copy_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         &__fold_result___1, &v_204);
      int_ k_final_0 = v_204.t0;
      FX_COPY_PTR(v_204.t1, &for_headers_2);
      _fx_R10Ast__loc_t ifor_loc_0;
      FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(n_exp_4, &ifor_loc_0, 0), _fx_catch_28);
      FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &ifor_loc_0, &v_205, 0), _fx_catch_28);
      FX_CALL(_fx_M6C_formFM11make_assignN14C_form__cexp_t2N14C_form__cexp_tN14C_form__cexp_t(i_exp_7, v_205, &v_206, 0),
         _fx_catch_28);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(v_206, 0, true, &init_exps_0), _fx_catch_28);
      _fx_N17C_form__cbinary_t v_218;
      _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpLT, &v_218);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &ifor_loc_0, &v_207);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &v_218, i_exp_7, n_exp_4, &v_207, &check_exp_0), _fx_catch_28);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g19C_gen_code__CTypInt, &ifor_loc_0, &v_208);
      FX_CALL(
         _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g24C_gen_code__COpSuffixInc, i_exp_7, &v_208, &v_209), _fx_catch_28);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(v_209, 0, true, &incr_exps_i_0), _fx_catch_28);
      if (k_final_0 > 0) {
         _fx_make_T2N14C_form__cexp_tLN14C_form__cexp_t(check_exp_0, incr_exps_i_0, &v_210);
      }
      else {
         FX_COPY_PTR(check_exp_0, &__fold_result___7);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(for_checks_0, &v_211, 0), _fx_catch_28);
         _fx_LN14C_form__cexp_t lst_6 = v_211;
         for (; lst_6; lst_6 = lst_6->tl) {
            _fx_N14C_form__cexp_t check_exp_3 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_219 = {0};
            _fx_N14C_form__cexp_t v_220 = 0;
            _fx_N14C_form__cexp_t e_1 = lst_6->hd;
            FX_COPY_PTR(__fold_result___7, &check_exp_3);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &ifor_loc_0, &v_219);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g23C_gen_code__COpLogicAnd, check_exp_3, e_1, &v_219, &v_220), _fx_catch_27);
            _fx_free_N14C_form__cexp_t(&__fold_result___7);
            FX_COPY_PTR(v_220, &__fold_result___7);

         _fx_catch_27: ;
            if (v_220) {
               _fx_free_N14C_form__cexp_t(&v_220);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_219);
            if (check_exp_3) {
               _fx_free_N14C_form__cexp_t(&check_exp_3);
            }
            FX_CHECK_EXN(_fx_catch_28);
         }
         FX_COPY_PTR(__fold_result___7, &check_exp_1);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(incr_exps_0, &v_212, 0), _fx_catch_28);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(incr_exps_i_0, v_212, &v_213, 0),
            _fx_catch_28);
         _fx_make_T2N14C_form__cexp_tLN14C_form__cexp_t(check_exp_1, v_213, &v_210);
      }
      FX_COPY_PTR(v_210.t0, &check_exp_2);
      FX_COPY_PTR(v_210.t1, &incr_exps_i_1);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__ctyp_t1N14C_form__ctyp_t(_fx_g19C_gen_code__CTypInt, &v_214);
      _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(check_exp_2, &v_215);
      _fx_make_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_214, init_exps_0,
         &v_215, incr_exps_i_1, &v_216);
      FX_CALL(
         _fx_cons_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_216,
            for_headers_2, false, &for_headers_2), _fx_catch_28);
      _fx_make_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(k_final_0 + 1,
         for_headers_2, &v_217);
      _fx_free_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         &__fold_result___1);
      _fx_copy_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_217,
         &__fold_result___1);

   _fx_catch_28: ;
      _fx_free_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_217);
      _fx_free_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_216);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_215);
      _fx_free_Nt6option1N14C_form__ctyp_t(&v_214);
      if (incr_exps_i_1) {
         _fx_free_LN14C_form__cexp_t(&incr_exps_i_1);
      }
      if (check_exp_2) {
         _fx_free_N14C_form__cexp_t(&check_exp_2);
      }
      if (v_213) {
         _fx_free_LN14C_form__cexp_t(&v_213);
      }
      if (v_212) {
         _fx_free_LN14C_form__cexp_t(&v_212);
      }
      if (check_exp_1) {
         _fx_free_N14C_form__cexp_t(&check_exp_1);
      }
      if (v_211) {
         _fx_free_LN14C_form__cexp_t(&v_211);
      }
      if (__fold_result___7) {
         _fx_free_N14C_form__cexp_t(&__fold_result___7);
      }
      _fx_free_T2N14C_form__cexp_tLN14C_form__cexp_t(&v_210);
      if (incr_exps_i_0) {
         _fx_free_LN14C_form__cexp_t(&incr_exps_i_0);
      }
      if (v_209) {
         _fx_free_N14C_form__cexp_t(&v_209);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_208);
      if (check_exp_0) {
         _fx_free_N14C_form__cexp_t(&check_exp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_207);
      if (init_exps_0) {
         _fx_free_LN14C_form__cexp_t(&init_exps_0);
      }
      if (v_206) {
         _fx_free_N14C_form__cexp_t(&v_206);
      }
      if (v_205) {
         _fx_free_N14C_form__cexp_t(&v_205);
      }
      if (for_headers_2) {
         _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&for_headers_2);
      }
      _fx_free_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_204);
      FX_CHECK_EXN(_fx_cleanup);
   }
   int s_0 = !lst_4 + !lst_5;
   FX_CHECK_EQ_SIZE(s_0 == 0 || s_0 == 2, _fx_cleanup);
   _fx_copy_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&__fold_result___1,
      &v_11);
   int_ k_final_1 = v_11.t0;
   FX_COPY_PTR(v_11.t1, &for_headers_0);
   if (k_final_1 > 0) {
      FX_COPY_PTR(for_headers_0, &for_headers_1);
   }
   else {
      _fx_copy_Nt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &__fold_result___2);
      FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(for_checks_0, &v_12, 0), _fx_cleanup);
      _fx_LN14C_form__cexp_t lst_7 = v_12;
      for (; lst_7; lst_7 = lst_7->tl) {
         _fx_Nt6option1N14C_form__cexp_t check_exp_opt_1 = {0};
         _fx_N14C_form__cexp_t v_221 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_222 = {0};
         _fx_N14C_form__cexp_t check_i_0 = lst_7->hd;
         _fx_copy_Nt6option1N14C_form__cexp_t(&__fold_result___2, &check_exp_opt_1);
         if (check_exp_opt_1.tag == 2) {
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_223 = {0};
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &for_loc_0, &v_223);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g23C_gen_code__COpLogicAnd, check_exp_opt_1.u.Some, check_i_0, &v_223, &v_221), _fx_catch_29);

         _fx_catch_29: ;
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_223);
         }
         else {
            FX_COPY_PTR(check_i_0, &v_221);
         }
         FX_CHECK_EXN(_fx_catch_30);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_221, &v_222);
         _fx_free_Nt6option1N14C_form__cexp_t(&__fold_result___2);
         _fx_copy_Nt6option1N14C_form__cexp_t(&v_222, &__fold_result___2);

      _fx_catch_30: ;
         _fx_free_Nt6option1N14C_form__cexp_t(&v_222);
         if (v_221) {
            _fx_free_N14C_form__cexp_t(&v_221);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&check_exp_opt_1);
         FX_CHECK_EXN(_fx_cleanup);
      }
      _fx_copy_Nt6option1N14C_form__cexp_t(&__fold_result___2, &check_exp_opt_0);
      _fx_make_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         &_fx_g18C_gen_code__None1_, 0, &check_exp_opt_0, incr_exps_0, &v_13);
      FX_CALL(
         _fx_cons_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_13, 0, true,
            &for_headers_1), _fx_cleanup);
   }
   FX_CALL(
      _fx_M10C_gen_codeFM3revLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         for_headers_1, &v_14, 0), _fx_cleanup);
   _fx_make_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t(
      v_14, list_exps_0, i_exps_0, n_exps_0, init_ccode_3, pre_body_ccode_1, body_elems_0, post_ccode_0, fx_result);

_fx_cleanup: ;
   FX_FREE_FP(&atom2cexp__0);
   FX_FREE_FP(&atom2cexp_0);
   FX_FREE_STR(&v_0);
   fx_free_exn(&v_1);
   _fx_free_T2LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_2);
   if (idoml_1) {
      _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&idoml_1);
   }
   FX_FREE_LIST_SIMPLE(&at_ids_1);
   _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
      &__fold_result___0);
   _fx_free_T10LN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN14C_form__cexp_t(
      &v_3);
   if (list_exps_0) {
      _fx_free_LN14C_form__cexp_t(&list_exps_0);
   }
   if (i_exps_0) {
      _fx_free_LN14C_form__cexp_t(&i_exps_0);
   }
   if (n_exps_0) {
      _fx_free_LN14C_form__cexp_t(&n_exps_0);
   }
   if (for_checks_0) {
      _fx_free_LN14C_form__cexp_t(&for_checks_0);
   }
   if (incr_exps_0) {
      _fx_free_LN14C_form__cexp_t(&incr_exps_0);
   }
   if (init_checks_0) {
      _fx_free_LN14C_form__cexp_t(&init_checks_0);
   }
   if (init_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&init_ccode_1);
   }
   if (pre_body_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_0);
   }
   if (body_elems_0) {
      _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&body_elems_0);
   }
   if (post_checks_0) {
      _fx_free_LN14C_form__cexp_t(&post_checks_0);
   }
   if (v_4) {
      _fx_free_LN14C_form__cexp_t(&v_4);
   }
   if (init_ccode_2) {
      _fx_free_LN15C_form__cstmt_t(&init_ccode_2);
   }
   _fx_free_Ta2LN15C_form__cstmt_t(&v_5);
   if (v_6) {
      _fx_free_LN15C_form__cstmt_t(&v_6);
   }
   if (init_ccode_3) {
      _fx_free_LN15C_form__cstmt_t(&init_ccode_3);
   }
   if (pre_body_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_1);
   }
   if (post_checks_1) {
      _fx_free_LN14C_form__cexp_t(&post_checks_1);
   }
   if (post_checks_2) {
      _fx_free_LN14C_form__cexp_t(&post_checks_2);
   }
   if (v_7) {
      _fx_free_N14C_form__cexp_t(&v_7);
   }
   if (v_8) {
      _fx_free_N14C_form__cexp_t(&v_8);
   }
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_9);
   if (v_10) {
      _fx_free_N14C_form__cexp_t(&v_10);
   }
   if (post_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&post_ccode_0);
   }
   _fx_free_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
      &__fold_result___1);
   _fx_free_T2iLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_11);
   if (for_headers_0) {
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&for_headers_0);
   }
   if (for_headers_1) {
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&for_headers_1);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&__fold_result___2);
   if (v_12) {
      _fx_free_LN14C_form__cexp_t(&v_12);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&check_exp_opt_0);
   _fx_free_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_13);
   if (v_14) {
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_14);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti*
      fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti_cldata_t,
      _fx_free_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti,
      _fx_M10C_gen_codeFM11process_forT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

static int _fx_M10C_gen_codeFM11get_iter_idR9Ast__id_t7iLR9Ast__id_tSiiR10Ast__loc_ti(
   int_ k_0,
   struct _fx_LR9Ast__id_t_data_t* at_ids_0,
   fx_str_t* prefix_0,
   int_ for_idx_0,
   int_ km_idx_0,
   struct _fx_R10Ast__loc_t* loc_0,
   int_ nfors_0,
   struct _fx_R9Ast__id_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (at_ids_0 == 0) {
      FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, prefix_0, fx_result, 0), _fx_catch_0);  _fx_catch_0: ;
   }
   else {
      _fx_LR9Ast__id_t l_0 = 0;
      fx_str_t for_msg_prefix_0 = {0};
      fx_str_t v_0 = {0};
      fx_str_t v_1 = {0};
      fx_str_t v_2 = {0};
      fx_str_t v_3 = {0};
      fx_str_t it_clause_0 = {0};
      fx_str_t v_4 = {0};
      fx_exn_t v_5 = {0};
      int_ v_6 = _fx_M10C_gen_codeFM6lengthi1LR9Ast__id_t(at_ids_0, 0);
      if (k_0 < v_6) {
         _fx_R9Ast__id_t result_0 = {0};
         FX_COPY_PTR(at_ids_0, &l_0);
         int_ n_0 = k_0;
         for (;;) {
            _fx_LR9Ast__id_t l_1 = 0;
            FX_COPY_PTR(l_0, &l_1);
            int_ n_1 = n_0;
            if (l_1 != 0) {
               if (n_1 == 0) {
                  result_0 = l_1->hd; FX_BREAK(_fx_catch_1);
               }
               else {
                  _fx_LR9Ast__id_t* rest_0 = &l_1->tl; FX_FREE_LIST_SIMPLE(&l_0); FX_COPY_PTR(*rest_0, &l_0); n_0 = n_1 - 1;
               }

            _fx_catch_1: ;
            }
            else {
               FX_FAST_THROW(FX_EXN_OutOfRangeError, _fx_catch_2);
            }
            FX_CHECK_EXN(_fx_catch_2);

         _fx_catch_2: ;
            FX_FREE_LIST_SIMPLE(&l_1);
            FX_CHECK_BREAK();
            FX_CHECK_EXN(_fx_catch_3);
         }
         *fx_result = result_0;
      }
      else {
         if (nfors_0 == 1) {
            fx_str_t slit_0 = FX_MAKE_STR(""); fx_copy_str(&slit_0, &for_msg_prefix_0);
         }
         else if (for_idx_0 == 0) {
            fx_str_t slit_1 = FX_MAKE_STR("the outermost "); fx_copy_str(&slit_1, &for_msg_prefix_0);
         }
         else if (for_idx_0 == nfors_0 - 1) {
            fx_str_t slit_2 = FX_MAKE_STR("the innermost "); fx_copy_str(&slit_2, &for_msg_prefix_0);
         }
         else {
            FX_CALL(_fx_F6stringS1i(for_idx_0, &v_0, 0), _fx_catch_3);
            FX_CALL(_fx_M6StringFM10num_suffixS1i(for_idx_0, &v_1, 0), _fx_catch_3);
            fx_str_t slit_3 = FX_MAKE_STR("-");
            fx_str_t slit_4 = FX_MAKE_STR(" nested ");
            {
               const fx_str_t strs_0[] = { v_0, slit_3, v_1, slit_4 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_0, 4, &for_msg_prefix_0), _fx_catch_3);
            }
         }
         FX_CALL(_fx_F6stringS1i(1, &v_2, 0), _fx_catch_3);
         FX_CALL(_fx_M6StringFM10num_suffixS1i(1, &v_3, 0), _fx_catch_3);
         fx_str_t slit_5 = FX_MAKE_STR(", ");
         fx_str_t slit_6 = FX_MAKE_STR("-");
         fx_str_t slit_7 = FX_MAKE_STR(" iteration clause");
         {
            const fx_str_t strs_1[] = { slit_5, v_2, slit_6, v_3, slit_7 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_1, 5, &it_clause_0), _fx_catch_3);
         }
         fx_str_t slit_8 = FX_MAKE_STR("cgen: ");
         fx_str_t slit_9 = FX_MAKE_STR("for-loop");
         fx_str_t slit_10 =
            FX_MAKE_STR(": the list of \'@\' indices is too short for array; looks like it\'s bug in type checker");
         {
            const fx_str_t strs_2[] = { slit_8, for_msg_prefix_0, slit_9, it_clause_0, slit_10 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_2, 5, &v_4), _fx_catch_3);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(loc_0, &v_4, &v_5, 0), _fx_catch_3);
         FX_THROW(&v_5, false, _fx_catch_3);
      }

   _fx_catch_3: ;
      fx_free_exn(&v_5);
      FX_FREE_STR(&v_4);
      FX_FREE_STR(&it_clause_0);
      FX_FREE_STR(&v_3);
      FX_FREE_STR(&v_2);
      FX_FREE_STR(&v_1);
      FX_FREE_STR(&v_0);
      FX_FREE_STR(&for_msg_prefix_0);
      FX_FREE_LIST_SIMPLE(&l_0);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM19decl_for_body_elemsLN15C_form__cstmt_t4LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
   struct _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t_data_t* body_elems_0,
   struct _fx_LN15C_form__cstmt_t_data_t* body_ccode_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_LN15C_form__cstmt_t __fold_result___0 = 0;
   int fx_status = 0;
   FX_COPY_PTR(body_ccode_0, &__fold_result___0);
   _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t lst_0 = body_elems_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_N14C_form__cexp_t e_0 = 0;
      _fx_R16Ast__val_flags_t flags_0 = {0};
      _fx_LN15C_form__cstmt_t body_ccode_1 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_0 = {0};
      _fx_N14C_form__ctyp_t ctyp_0 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_2 = {0};
      _fx_LN15C_form__cstmt_t body_ccode_2 = 0;
      _fx_T3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t* __pat___0 = &lst_0->hd;
      _fx_R9Ast__id_t v_3 = __pat___0->t0;
      FX_COPY_PTR(__pat___0->t1, &e_0);
      _fx_copy_R16Ast__val_flags_t(&__pat___0->t2, &flags_0);
      FX_COPY_PTR(__fold_result___0, &body_ccode_1);
      FX_CALL(_fx_M6C_formFM12get_cexp_ctxT2N14C_form__ctyp_tR10Ast__loc_t1N14C_form__cexp_t(e_0, &v_0, 0), _fx_catch_0);
      FX_COPY_PTR(v_0.t0, &ctyp_0);
      _fx_R10Ast__loc_t loc_0 = v_0.t1;
      if (flags_0.val_flag_tempref) {
         FX_CALL(
            _fx_M10C_gen_codeFM17add_local_temprefT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
               &v_3, ctyp_0, &flags_0, e_0, body_ccode_1, &loc_0, i2e_ref_0, &v_1, 0), _fx_catch_0);
      }
      else {
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(e_0, &v_2);
         FX_CALL(
            _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               &v_3, ctyp_0, &flags_0, &v_2, body_ccode_1, &loc_0, block_stack_ref_0, &v_1, 0), _fx_catch_0);
      }
      FX_COPY_PTR(v_1.t1, &body_ccode_2);
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
      FX_COPY_PTR(body_ccode_2, &__fold_result___0);

   _fx_catch_0: ;
      if (body_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_2);
      }
      _fx_free_Nt6option1N14C_form__cexp_t(&v_2);
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1);
      if (ctyp_0) {
         _fx_free_N14C_form__ctyp_t(&ctyp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_0);
      if (body_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_1);
      }
      _fx_free_R16Ast__val_flags_t(&flags_0);
      if (e_0) {
         _fx_free_N14C_form__cexp_t(&e_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___0, fx_result);

_fx_cleanup: ;
   if (__fold_result___0) {
      _fx_free_LN15C_form__cstmt_t(&__fold_result___0);
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t_data_t* cases_0,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   bool is_catch_case_0,
   struct _fx_R10Ast__loc_t* kloc_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   struct _fx_LN15C_form__cstmt_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t
      kexp2cexp_0 = {0};
   fx_str_t v_0 = {0};
   fx_str_t basename_0 = {0};
   fx_str_t cname_0 = {0};
   _fx_R19C_form__cdeflabel_t v_1 = {0};
   _fx_N15C_form__cinfo_t v_2 = {0};
   _fx_T5BBBBLLN15C_form__cstmt_t __fold_result___0 = {0};
   _fx_T5BBBBLLN15C_form__cstmt_t v_3 = {0};
   _fx_LLN15C_form__cstmt_t all_cases_ccode_0 = 0;
   _fx_N14C_form__cexp_t parent_lbl_0 = 0;
   _fx_LLN15C_form__cstmt_t all_cases_ccode_1 = 0;
   _fx_N14C_form__cexp_t no_match_err_0 = 0;
   _fx_LN14C_form__cexp_t v_4 = 0;
   _fx_N14C_form__cexp_t throw_no_match_0 = 0;
   _fx_N15C_form__cstmt_t v_5 = 0;
   _fx_LN15C_form__cstmt_t v_6 = 0;
   _fx_T2BLN15C_form__cstmt_t v_7 = {0};
   _fx_LN15C_form__cstmt_t ccode_1 = 0;
   _fx_LN15C_form__cstmt_t ccode_2 = 0;
   _fx_N15C_form__cstmt_t v_8 = 0;
   _fx_LN14C_form__cexp_t v_9 = 0;
   _fx_N14C_form__cexp_t check_exn_0 = 0;
   _fx_N15C_form__cstmt_t v_10 = 0;
   int fx_status = 0;
   _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*)
         fx_fv;
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      cv_0->t0, cv_0->t1, cv_0->t2, cv_0->t3, cv_0->t4, &kexp2cexp_0);
   _fx_LrR23C_gen_code__block_ctx_t* block_stack_0 = &block_stack_ref_0->data;
   _fx_R10Ast__loc_t end_loc_0;
   FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(kloc_0, &end_loc_0, 0), _fx_cleanup);
   if (is_catch_case_0) {
      fx_str_t slit_0 = FX_MAKE_STR("endcatch"); fx_copy_str(&slit_0, &v_0);
   }
   else {
      fx_str_t slit_1 = FX_MAKE_STR("endmatch"); fx_copy_str(&slit_1, &v_0);
   }
   bool v_11;
   fx_str_t slit_2 = FX_MAKE_STR("_fx_");
   v_11 = _fx_M6StringFM10startswithB2SS(&v_0, &slit_2, 0);
   if (v_11) {
      fx_copy_str(&v_0, &basename_0);
   }
   else {
      fx_str_t slit_3 = FX_MAKE_STR("_fx_");
      {
         const fx_str_t strs_0[] = { slit_3, v_0 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_0, 2, &basename_0), _fx_cleanup);
      }
   }
   _fx_R9Ast__id_t li_0;
   FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &basename_0, &li_0, 0), _fx_cleanup);
   bool v_12;
   fx_str_t slit_4 = FX_MAKE_STR("_fx_cleanup");
   v_12 = _fx_F6__eq__B2SS(&basename_0, &slit_4, 0);
   if (v_12) {
      fx_copy_str(&basename_0, &cname_0);
   }
   else {
      fx_str_t slit_5 = FX_MAKE_STR(""); fx_copy_str(&slit_5, &cname_0);
   }
   _fx_make_R19C_form__cdeflabel_t(&li_0, &cname_0, &end_loc_0, &v_1);
   _fx_M6C_formFM6CLabelN15C_form__cinfo_t1RM11cdeflabel_t(&v_1, &v_2);
   FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(&li_0, &v_2, 0), _fx_cleanup);
   _fx_make_T5BBBBLLN15C_form__cstmt_t(false, false, false, false, 0, &__fold_result___0);
   _fx_LT2LN14K_form__kexp_tN14K_form__kexp_t lst_0 = cases_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_LN14K_form__kexp_t checks_i_0 = 0;
      _fx_N14K_form__kexp_t action_i_0 = 0;
      _fx_T5BBBBLLN15C_form__cstmt_t v_13 = {0};
      _fx_LLN15C_form__cstmt_t all_cases_ccode_2 = 0;
      _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t __fold_result___1 = {0};
      _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t v_14 = {0};
      _fx_LN14C_form__cexp_t cchecks_i_0 = 0;
      _fx_LLN15C_form__cstmt_t pre_cchecks_i_0 = 0;
      _fx_T3LN15C_form__cstmt_tBB v_15 = {0};
      _fx_LN15C_form__cstmt_t ai_ccode_0 = 0;
      _fx_LN15C_form__cstmt_t case_ccode_0 = 0;
      _fx_T5BBBBLLN15C_form__cstmt_t v_16 = {0};
      _fx_T2LN14K_form__kexp_tN14K_form__kexp_t* __pat___0 = &lst_0->hd;
      FX_COPY_PTR(__pat___0->t0, &checks_i_0);
      FX_COPY_PTR(__pat___0->t1, &action_i_0);
      _fx_copy_T5BBBBLLN15C_form__cstmt_t(&__fold_result___0, &v_13);
      bool have_default_0 = v_13.t0;
      FX_COPY_PTR(v_13.t4, &all_cases_ccode_2);
      _fx_make_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(0, 0, &__fold_result___1);
      _fx_LN14K_form__kexp_t lst_1 = checks_i_0;
      for (; lst_1; lst_1 = lst_1->tl) {
         _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t v_17 = {0};
         _fx_LN14C_form__cexp_t checks_i_1 = 0;
         _fx_LLN15C_form__cstmt_t pre_checks_i_0 = 0;
         _fx_rNt6option1N14C_form__cexp_t v_18 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_19 = {0};
         _fx_N14C_form__cexp_t ccheck_ij_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_ij_0 = 0;
         _fx_T2LN14C_form__cexp_tLLN15C_form__cstmt_t v_20 = {0};
         _fx_N14K_form__kexp_t check_ij_0 = lst_1->hd;
         _fx_copy_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&__fold_result___1, &v_17);
         FX_COPY_PTR(v_17.t0, &checks_i_1);
         FX_COPY_PTR(v_17.t1, &pre_checks_i_0);
         FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_18), _fx_catch_0);
         FX_CALL(
            kexp2cexp_0.fp(check_ij_0, v_18, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
               fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
               return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_19, kexp2cexp_0.fcv), _fx_catch_0);
         FX_COPY_PTR(v_19.t0, &ccheck_ij_0);
         FX_COPY_PTR(v_19.t1, &ccode_ij_0);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(ccheck_ij_0, checks_i_1, false, &checks_i_1), _fx_catch_0);
         FX_CALL(_fx_cons_LLN15C_form__cstmt_t(ccode_ij_0, pre_checks_i_0, false, &pre_checks_i_0), _fx_catch_0);
         _fx_make_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(checks_i_1, pre_checks_i_0, &v_20);
         _fx_free_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&__fold_result___1);
         _fx_copy_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&v_20, &__fold_result___1);

      _fx_catch_0: ;
         _fx_free_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&v_20);
         if (ccode_ij_0) {
            _fx_free_LN15C_form__cstmt_t(&ccode_ij_0);
         }
         if (ccheck_ij_0) {
            _fx_free_N14C_form__cexp_t(&ccheck_ij_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_19);
         if (v_18) {
            _fx_free_rNt6option1N14C_form__cexp_t(&v_18);
         }
         if (pre_checks_i_0) {
            _fx_free_LLN15C_form__cstmt_t(&pre_checks_i_0);
         }
         if (checks_i_1) {
            _fx_free_LN14C_form__cexp_t(&checks_i_1);
         }
         _fx_free_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&v_17);
         FX_CHECK_EXN(_fx_catch_15);
      }
      _fx_copy_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&__fold_result___1, &v_14);
      FX_COPY_PTR(v_14.t0, &cchecks_i_0);
      FX_COPY_PTR(v_14.t1, &pre_cchecks_i_0);
      _fx_R10Ast__loc_t ai_loc_0;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(action_i_0, &ai_loc_0, 0), _fx_catch_15);
      bool new_have_default_0;
      if (checks_i_0 == 0) {
         fx_exn_t v_21 = {0};
         if (have_default_0) {
            fx_str_t slit_6 = FX_MAKE_STR("cgen: more than one default action");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&ai_loc_0, &slit_6, &v_21, 0), _fx_catch_1);
            FX_THROW(&v_21, false, _fx_catch_1);
         }
         else {
            new_have_default_0 = true;
         }

      _fx_catch_1: ;
         fx_free_exn(&v_21);
      }
      else {
         new_have_default_0 = have_default_0;
      }
      FX_CHECK_EXN(_fx_catch_15);
      _fx_R10Ast__loc_t ai_end_loc_0;
      FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(&ai_loc_0, &ai_end_loc_0, 0), _fx_catch_15);
      if (FX_REC_VARIANT_TAG(action_i_0) == 24) {
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_22 = {0};
         _fx_LN15C_form__cstmt_t ai_ccode_1 = 0;
         FX_CALL(
            kexp2cexp_0.fp(action_i_0, dstexp_r_0, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
               fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
               return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_22, kexp2cexp_0.fcv), _fx_catch_2);
         FX_COPY_PTR(v_22.t1, &ai_ccode_1);
         _fx_make_T3LN15C_form__cstmt_tBB(ai_ccode_1, false, false, &v_15);

      _fx_catch_2: ;
         if (ai_ccode_1) {
            _fx_free_LN15C_form__cstmt_t(&ai_ccode_1);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_22);
      }
      else {
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_23 = {0};
         _fx_LN15C_form__cstmt_t ai_ccode_2 = 0;
         _fx_LrR23C_gen_code__block_ctx_t block_stack_1 = 0;
         _fx_rR23C_gen_code__block_ctx_t bctx_i_0 = 0;
         _fx_LN15C_form__cstmt_t bctx_cleanup_0 = 0;
         _fx_LN15C_form__cstmt_t bctx_prologue_0 = 0;
         _fx_LN15C_form__cstmt_t __fold_result___2 = 0;
         _fx_LN15C_form__cstmt_t epilogue_0 = 0;
         _fx_LN15C_form__cstmt_t epilogue_1 = 0;
         _fx_N15C_form__cstmt_t v_24 = 0;
         _fx_LN15C_form__cstmt_t v_25 = 0;
         _fx_LrR23C_gen_code__block_ctx_t block_stack_2 = 0;
         _fx_T2BLN15C_form__cstmt_t v_26 = {0};
         _fx_N15C_form__cstmt_t v_27 = 0;
         _fx_LN15C_form__cstmt_t v_28 = 0;
         _fx_LN15C_form__cstmt_t epilogue_2 = 0;
         _fx_LN15C_form__cstmt_t v_29 = 0;
         _fx_LN15C_form__cstmt_t ai_ccode_3 = 0;
         _fx_R16Ast__for_flags_t v_30;
         FX_CALL(_fx_M3AstFM17default_for_flagsRM11for_flags_t0(&v_30, 0), _fx_catch_12);
         FX_CALL(
            _fx_M10C_gen_codeFM14new_block_ctx_v5N24C_gen_code__block_kind_tR16Ast__for_flags_tR10Ast__loc_trLrRM11block_ctx_ti(
               &_fx_g26C_gen_code__BlockKind_Case, &v_30, &ai_loc_0, block_stack_ref_0, km_idx_0, 0), _fx_catch_12);
         FX_CALL(
            kexp2cexp_0.fp(action_i_0, dstexp_r_0, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
               fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
               return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_23, kexp2cexp_0.fcv), _fx_catch_12);
         FX_COPY_PTR(v_23.t1, &ai_ccode_2);
         FX_COPY_PTR(*block_stack_0, &block_stack_1);
         if (block_stack_1 != 0) {
            FX_COPY_PTR(block_stack_1->hd, &bctx_i_0);
         }
         else {
            fx_exn_t v_31 = {0};
            fx_str_t slit_7 = FX_MAKE_STR("cgen: empty block stack!");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(kloc_0, &slit_7, &v_31, 0), _fx_catch_3);
            FX_THROW(&v_31, false, _fx_catch_3);

         _fx_catch_3: ;
            fx_free_exn(&v_31);
         }
         FX_CHECK_EXN(_fx_catch_12);
         _fx_R23C_gen_code__block_ctx_t* v_32 = &bctx_i_0->data;
         int_ bctx_label_used_0 = v_32->bctx_label_used;
         _fx_R9Ast__id_t bctx_label_0 = v_32->bctx_label;
         FX_COPY_PTR(v_32->bctx_cleanup, &bctx_cleanup_0);
         FX_COPY_PTR(v_32->bctx_prologue, &bctx_prologue_0);
         _fx_LN15C_form__cstmt_t lst_2 = bctx_cleanup_0;
         for (; lst_2; lst_2 = lst_2->tl) {
            _fx_LN15C_form__cstmt_t r_0 = 0;
            _fx_N15C_form__cstmt_t a_0 = lst_2->hd;
            FX_COPY_PTR(__fold_result___2, &r_0);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(a_0, r_0, false, &r_0), _fx_catch_4);
            _fx_free_LN15C_form__cstmt_t(&__fold_result___2);
            FX_COPY_PTR(r_0, &__fold_result___2);

         _fx_catch_4: ;
            if (r_0) {
               _fx_free_LN15C_form__cstmt_t(&r_0);
            }
            FX_CHECK_EXN(_fx_catch_12);
         }
         FX_COPY_PTR(__fold_result___2, &epilogue_0);
         if (bctx_label_used_0 == 0) {
            FX_COPY_PTR(epilogue_0, &epilogue_1);
         }
         else {
            FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&bctx_label_0, &ai_end_loc_0, &v_24),
               _fx_catch_12);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_24, 0, true, &v_25), _fx_catch_12);
            if (epilogue_0 == 0) {
               FX_COPY_PTR(v_25, &epilogue_1);
            }
            else if (v_25 == 0) {
               FX_COPY_PTR(epilogue_0, &epilogue_1);
            }
            else {
               _fx_LN15C_form__cstmt_t v_33 = 0;
               _fx_LN15C_form__cstmt_t lstend_0 = 0;
               _fx_LN15C_form__cstmt_t lst_3 = epilogue_0;
               for (; lst_3; lst_3 = lst_3->tl) {
                  _fx_N15C_form__cstmt_t x_0 = lst_3->hd;
                  _fx_LN15C_form__cstmt_t node_0 = 0;
                  FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_0, 0, false, &node_0), _fx_catch_5);
                  FX_LIST_APPEND(v_33, lstend_0, node_0);

               _fx_catch_5: ;
                  FX_CHECK_EXN(_fx_catch_6);
               }
               _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_33, v_25, &epilogue_1, 0);

            _fx_catch_6: ;
               if (v_33) {
                  _fx_free_LN15C_form__cstmt_t(&v_33);
               }
            }
            FX_CHECK_EXN(_fx_catch_12);
         }
         FX_COPY_PTR(*block_stack_0, &block_stack_2);
         if (block_stack_2 != 0) {
            _fx_LrR23C_gen_code__block_ctx_t* rest_0 = &block_stack_2->tl;
            _fx_free_LrR23C_gen_code__block_ctx_t(block_stack_0);
            FX_COPY_PTR(*rest_0, block_stack_0);
         }
         else {
            fx_exn_t v_34 = {0};
            fx_str_t slit_8 = FX_MAKE_STR("cgen: empty block stack!");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&ai_end_loc_0, &slit_8, &v_34, 0), _fx_catch_7);
            FX_THROW(&v_34, false, _fx_catch_7);

         _fx_catch_7: ;
            fx_free_exn(&v_34);
         }
         FX_CHECK_EXN(_fx_catch_12);
         if (new_have_default_0) {
            _fx_make_T2BLN15C_form__cstmt_t(false, epilogue_1, &v_26);
         }
         else {
            FX_CALL(_fx_M6C_formFM9CStmtGotoN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&li_0, &ai_end_loc_0, &v_27),
               _fx_catch_12);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_27, epilogue_1, true, &v_28), _fx_catch_12);
            _fx_make_T2BLN15C_form__cstmt_t(true, v_28, &v_26);
         }
         bool em_label_used_i_0 = v_26.t0;
         FX_COPY_PTR(v_26.t1, &epilogue_2);
         if (ai_ccode_2 == 0) {
            FX_COPY_PTR(bctx_prologue_0, &v_29);
         }
         else if (bctx_prologue_0 == 0) {
            FX_COPY_PTR(ai_ccode_2, &v_29);
         }
         else {
            _fx_LN15C_form__cstmt_t v_35 = 0;
            _fx_LN15C_form__cstmt_t lstend_1 = 0;
            _fx_LN15C_form__cstmt_t lst_4 = ai_ccode_2;
            for (; lst_4; lst_4 = lst_4->tl) {
               _fx_N15C_form__cstmt_t x_1 = lst_4->hd;
               _fx_LN15C_form__cstmt_t node_1 = 0;
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_1, 0, false, &node_1), _fx_catch_8);
               FX_LIST_APPEND(v_35, lstend_1, node_1);

            _fx_catch_8: ;
               FX_CHECK_EXN(_fx_catch_9);
            }
            _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_35, bctx_prologue_0, &v_29,
               0);

         _fx_catch_9: ;
            if (v_35) {
               _fx_free_LN15C_form__cstmt_t(&v_35);
            }
         }
         FX_CHECK_EXN(_fx_catch_12);
         if (epilogue_2 == 0) {
            FX_COPY_PTR(v_29, &ai_ccode_3);
         }
         else if (v_29 == 0) {
            FX_COPY_PTR(epilogue_2, &ai_ccode_3);
         }
         else {
            _fx_LN15C_form__cstmt_t v_36 = 0;
            _fx_LN15C_form__cstmt_t lstend_2 = 0;
            _fx_LN15C_form__cstmt_t lst_5 = epilogue_2;
            for (; lst_5; lst_5 = lst_5->tl) {
               _fx_N15C_form__cstmt_t x_2 = lst_5->hd;
               _fx_LN15C_form__cstmt_t node_2 = 0;
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_2, 0, false, &node_2), _fx_catch_10);
               FX_LIST_APPEND(v_36, lstend_2, node_2);

            _fx_catch_10: ;
               FX_CHECK_EXN(_fx_catch_11);
            }
            _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_36, v_29, &ai_ccode_3, 0);

         _fx_catch_11: ;
            if (v_36) {
               _fx_free_LN15C_form__cstmt_t(&v_36);
            }
         }
         FX_CHECK_EXN(_fx_catch_12);
         _fx_make_T3LN15C_form__cstmt_tBB(ai_ccode_3, em_label_used_i_0, true, &v_15);

      _fx_catch_12: ;
         if (ai_ccode_3) {
            _fx_free_LN15C_form__cstmt_t(&ai_ccode_3);
         }
         if (v_29) {
            _fx_free_LN15C_form__cstmt_t(&v_29);
         }
         if (epilogue_2) {
            _fx_free_LN15C_form__cstmt_t(&epilogue_2);
         }
         if (v_28) {
            _fx_free_LN15C_form__cstmt_t(&v_28);
         }
         if (v_27) {
            _fx_free_N15C_form__cstmt_t(&v_27);
         }
         _fx_free_T2BLN15C_form__cstmt_t(&v_26);
         if (block_stack_2) {
            _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_2);
         }
         if (v_25) {
            _fx_free_LN15C_form__cstmt_t(&v_25);
         }
         if (v_24) {
            _fx_free_N15C_form__cstmt_t(&v_24);
         }
         if (epilogue_1) {
            _fx_free_LN15C_form__cstmt_t(&epilogue_1);
         }
         if (epilogue_0) {
            _fx_free_LN15C_form__cstmt_t(&epilogue_0);
         }
         if (__fold_result___2) {
            _fx_free_LN15C_form__cstmt_t(&__fold_result___2);
         }
         if (bctx_prologue_0) {
            _fx_free_LN15C_form__cstmt_t(&bctx_prologue_0);
         }
         if (bctx_cleanup_0) {
            _fx_free_LN15C_form__cstmt_t(&bctx_cleanup_0);
         }
         if (bctx_i_0) {
            _fx_free_rR23C_gen_code__block_ctx_t(&bctx_i_0);
         }
         if (block_stack_1) {
            _fx_free_LrR23C_gen_code__block_ctx_t(&block_stack_1);
         }
         if (ai_ccode_2) {
            _fx_free_LN15C_form__cstmt_t(&ai_ccode_2);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_23);
      }
      FX_CHECK_EXN(_fx_catch_15);
      FX_COPY_PTR(v_15.t0, &ai_ccode_0);
      bool em_label_used_i_1 = v_15.t1;
      bool have_epilogue_i_0 = v_15.t2;
      bool complex_branch_i_0;
      if (pre_cchecks_i_0 == 0) {
         if (cchecks_i_0 == 0) {
            complex_branch_i_0 = false; goto _fx_endmatch_0;
         }
      }
      if (pre_cchecks_i_0 != 0) {
         if (pre_cchecks_i_0->tl == 0) {
            if (pre_cchecks_i_0->hd == 0) {
               if (cchecks_i_0 != 0) {
                  if (cchecks_i_0->tl == 0) {
                     complex_branch_i_0 = false; goto _fx_endmatch_0;
                  }
               }
            }
         }
      }
      complex_branch_i_0 = true;

   _fx_endmatch_0: ;
      FX_CHECK_EXN(_fx_catch_15);
      if (pre_cchecks_i_0 == 0) {
         if (cchecks_i_0 == 0) {
            FX_COPY_PTR(ai_ccode_0, &case_ccode_0); goto _fx_endmatch_1;
         }
      }
      _fx_N15C_form__cstmt_t ai_stmt_0 = 0;
      _fx_LN15C_form__cstmt_t __fold_result___3 = 0;
      FX_CALL(
         _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(ai_ccode_0, &ai_loc_0, &ai_stmt_0, 0),
         _fx_catch_14);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(ai_stmt_0, 0, true, &__fold_result___3), _fx_catch_14);
      _fx_LN14C_form__cexp_t lst_6 = cchecks_i_0;
      _fx_LLN15C_form__cstmt_t lst_7 = pre_cchecks_i_0;
      for (; lst_6 && lst_7; lst_7 = lst_7->tl, lst_6 = lst_6->tl) {
         _fx_LN15C_form__cstmt_t case_ccode_1 = 0;
         _fx_N15C_form__cstmt_t case_stmt_0 = 0;
         _fx_N15C_form__cstmt_t v_37 = 0;
         _fx_N15C_form__cstmt_t if_stmt_0 = 0;
         _fx_LN15C_form__cstmt_t v_38 = 0;
         _fx_LN15C_form__cstmt_t pre_check_ij_0 = lst_7->hd;
         _fx_N14C_form__cexp_t check_ij_1 = lst_6->hd;
         FX_COPY_PTR(__fold_result___3, &case_ccode_1);
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(case_ccode_1, &ai_end_loc_0,
               &case_stmt_0, 0), _fx_catch_13);
         _fx_R10Ast__loc_t checkij_loc_0;
         FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(check_ij_1, &checkij_loc_0, 0), _fx_catch_13);
         FX_CALL(_fx_M6C_formFM8CStmtNopN15C_form__cstmt_t1R10Ast__loc_t(&ai_end_loc_0, &v_37), _fx_catch_13);
         FX_CALL(
            _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
               check_ij_1, case_stmt_0, v_37, &checkij_loc_0, &if_stmt_0, 0), _fx_catch_13);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(if_stmt_0, pre_check_ij_0, true, &v_38), _fx_catch_13);
         _fx_free_LN15C_form__cstmt_t(&__fold_result___3);
         FX_COPY_PTR(v_38, &__fold_result___3);

      _fx_catch_13: ;
         if (v_38) {
            _fx_free_LN15C_form__cstmt_t(&v_38);
         }
         if (if_stmt_0) {
            _fx_free_N15C_form__cstmt_t(&if_stmt_0);
         }
         if (v_37) {
            _fx_free_N15C_form__cstmt_t(&v_37);
         }
         if (case_stmt_0) {
            _fx_free_N15C_form__cstmt_t(&case_stmt_0);
         }
         if (case_ccode_1) {
            _fx_free_LN15C_form__cstmt_t(&case_ccode_1);
         }
         FX_CHECK_EXN(_fx_catch_14);
      }
      int s_0 = !lst_6 + !lst_7;
      FX_CHECK_EQ_SIZE(s_0 == 0 || s_0 == 2, _fx_catch_14);
      FX_COPY_PTR(__fold_result___3, &case_ccode_0);

   _fx_catch_14: ;
      if (__fold_result___3) {
         _fx_free_LN15C_form__cstmt_t(&__fold_result___3);
      }
      if (ai_stmt_0) {
         _fx_free_N15C_form__cstmt_t(&ai_stmt_0);
      }

   _fx_endmatch_1: ;
      FX_CHECK_EXN(_fx_catch_15);
      bool t_0;
      if (v_13.t1) {
         t_0 = true;
      }
      else {
         t_0 = em_label_used_i_1;
      }
      bool t_1;
      if (v_13.t2) {
         t_1 = true;
      }
      else {
         t_1 = have_epilogue_i_0;
      }
      bool t_2;
      if (v_13.t3) {
         t_2 = true;
      }
      else {
         t_2 = complex_branch_i_0;
      }
      FX_CALL(_fx_cons_LLN15C_form__cstmt_t(case_ccode_0, all_cases_ccode_2, false, &all_cases_ccode_2), _fx_catch_15);
      _fx_make_T5BBBBLLN15C_form__cstmt_t(new_have_default_0, t_0, t_1, t_2, all_cases_ccode_2, &v_16);
      _fx_free_T5BBBBLLN15C_form__cstmt_t(&__fold_result___0);
      _fx_copy_T5BBBBLLN15C_form__cstmt_t(&v_16, &__fold_result___0);

   _fx_catch_15: ;
      _fx_free_T5BBBBLLN15C_form__cstmt_t(&v_16);
      if (case_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&case_ccode_0);
      }
      if (ai_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&ai_ccode_0);
      }
      _fx_free_T3LN15C_form__cstmt_tBB(&v_15);
      if (pre_cchecks_i_0) {
         _fx_free_LLN15C_form__cstmt_t(&pre_cchecks_i_0);
      }
      if (cchecks_i_0) {
         _fx_free_LN14C_form__cexp_t(&cchecks_i_0);
      }
      _fx_free_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&v_14);
      _fx_free_T2LN14C_form__cexp_tLLN15C_form__cstmt_t(&__fold_result___1);
      if (all_cases_ccode_2) {
         _fx_free_LLN15C_form__cstmt_t(&all_cases_ccode_2);
      }
      _fx_free_T5BBBBLLN15C_form__cstmt_t(&v_13);
      if (action_i_0) {
         _fx_free_N14K_form__kexp_t(&action_i_0);
      }
      if (checks_i_0) {
         _fx_free_LN14K_form__kexp_t(&checks_i_0);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T5BBBBLLN15C_form__cstmt_t(&__fold_result___0, &v_3);
   bool have_default_1 = v_3.t0;
   bool em_label_used_0 = v_3.t1;
   bool have_epilogues_0 = v_3.t2;
   bool have_complex_branches_0 = v_3.t3;
   FX_COPY_PTR(v_3.t4, &all_cases_ccode_0);
   FX_CALL(
      _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&end_loc_0, block_stack_ref_0,
         &parent_lbl_0, 0), _fx_cleanup);
   if (have_default_1) {
      FX_COPY_PTR(all_cases_ccode_0, &all_cases_ccode_1);
   }
   else {
      _fx_R9Ast__id_t v_39;
      fx_str_t slit_9 = FX_MAKE_STR("FX_EXN_NoMatchError");
      FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_9, &v_39, 0), _fx_cleanup);
      FX_CALL(
         _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&v_39,
            _fx_g20C_gen_code__CTypCInt, &end_loc_0, &no_match_err_0, 0), _fx_cleanup);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(parent_lbl_0, 0, true, &v_4), _fx_cleanup);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(no_match_err_0, v_4, false, &v_4), _fx_cleanup);
      FX_CALL(
         _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g25C_form__std_FX_FAST_THROW, v_4, _fx_g20C_gen_code__CTypVoid, &end_loc_0, &throw_no_match_0, 0),
         _fx_cleanup);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(throw_no_match_0, &v_5), _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_5, 0, true, &v_6), _fx_cleanup);
      FX_CALL(_fx_cons_LLN15C_form__cstmt_t(v_6, all_cases_ccode_0, true, &all_cases_ccode_1), _fx_cleanup);
   }
   if (have_complex_branches_0 == false) {
      if (all_cases_ccode_1 != 0) {
         _fx_N15C_form__cstmt_t __fold_result___4 = 0;
         _fx_LLN15C_form__cstmt_t ifs_0 = 0;
         _fx_N15C_form__cstmt_t complex_if_0 = 0;
         _fx_LN15C_form__cstmt_t v_40 = 0;
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(all_cases_ccode_1->hd, &end_loc_0,
               &__fold_result___4, 0), _fx_catch_21);
         FX_COPY_PTR(all_cases_ccode_1->tl, &ifs_0);
         _fx_LLN15C_form__cstmt_t lst_8 = ifs_0;
         for (; lst_8; lst_8 = lst_8->tl) {
            _fx_N15C_form__cstmt_t complex_if_1 = 0;
            _fx_N15C_form__cstmt_t v_41 = 0;
            _fx_LN15C_form__cstmt_t s_i_0 = lst_8->hd;
            FX_COPY_PTR(__fold_result___4, &complex_if_1);
            if (s_i_0 != 0) {
               if (s_i_0->tl == 0) {
                  _fx_N15C_form__cstmt_t v_42 = s_i_0->hd;
                  if (FX_REC_VARIANT_TAG(v_42) == 9) {
                     _fx_T4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t* vcase_0 = &v_42->u.CStmtIf;
                     if (FX_REC_VARIANT_TAG(vcase_0->t2) == 1) {
                        _fx_LN15C_form__cstmt_t v_43 = 0;
                        _fx_LN15C_form__cstmt_t __fold_result___5 = 0;
                        _fx_LN15C_form__cstmt_t v_44 = 0;
                        _fx_N15C_form__cstmt_t then_i_0 = 0;
                        _fx_R10Ast__loc_t* loc_i_0 = &vcase_0->t3;
                        _fx_N15C_form__cstmt_t then_i_1 = vcase_0->t1;
                        FX_CALL(_fx_M6C_formFM10stmt2ccodeLN15C_form__cstmt_t1N15C_form__cstmt_t(then_i_1, &v_43, 0),
                           _fx_catch_18);
                        _fx_LN15C_form__cstmt_t lst_9 = v_43;
                        for (; lst_9; lst_9 = lst_9->tl) {
                           _fx_LN15C_form__cstmt_t r_1 = 0;
                           _fx_N15C_form__cstmt_t a_1 = lst_9->hd;
                           FX_COPY_PTR(__fold_result___5, &r_1);
                           FX_CALL(_fx_cons_LN15C_form__cstmt_t(a_1, r_1, false, &r_1), _fx_catch_16);
                           _fx_free_LN15C_form__cstmt_t(&__fold_result___5);
                           FX_COPY_PTR(r_1, &__fold_result___5);

                        _fx_catch_16: ;
                           if (r_1) {
                              _fx_free_LN15C_form__cstmt_t(&r_1);
                           }
                           FX_CHECK_EXN(_fx_catch_18);
                        }
                        FX_COPY_PTR(__fold_result___5, &v_44);
                        if (v_44 != 0) {
                           _fx_N15C_form__cstmt_t v_45 = v_44->hd;
                           if (FX_REC_VARIANT_TAG(v_45) == 10) {
                              bool res_0;
                              FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&v_45->u.CStmtGoto.t0, &li_0, &res_0, 0),
                                 _fx_catch_18);
                              if (res_0) {
                                 FX_CALL(
                                    _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(v_44->tl,
                                       loc_i_0, &then_i_0, 0), _fx_catch_17);

                              _fx_catch_17: ;
                                 goto _fx_endmatch_2;
                              }
                           }
                        }
                        FX_COPY_PTR(then_i_1, &then_i_0);

                     _fx_endmatch_2: ;
                        FX_CHECK_EXN(_fx_catch_18);
                        FX_CALL(
                           _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
                              vcase_0->t0, then_i_0, complex_if_1, loc_i_0, &v_41, 0), _fx_catch_18);

                     _fx_catch_18: ;
                        if (then_i_0) {
                           _fx_free_N15C_form__cstmt_t(&then_i_0);
                        }
                        if (v_44) {
                           _fx_free_LN15C_form__cstmt_t(&v_44);
                        }
                        if (__fold_result___5) {
                           _fx_free_LN15C_form__cstmt_t(&__fold_result___5);
                        }
                        if (v_43) {
                           _fx_free_LN15C_form__cstmt_t(&v_43);
                        }
                        goto _fx_endmatch_3;
                     }
                  }
               }
            }
            fx_exn_t v_46 = {0};
            fx_str_t slit_10 = FX_MAKE_STR("cgen: unexpected statement in the chained match statement");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&end_loc_0, &slit_10, &v_46, 0), _fx_catch_19);
            FX_THROW(&v_46, false, _fx_catch_19);

         _fx_catch_19: ;
            fx_free_exn(&v_46);

         _fx_endmatch_3: ;
            FX_CHECK_EXN(_fx_catch_20);
            _fx_free_N15C_form__cstmt_t(&__fold_result___4);
            FX_COPY_PTR(v_41, &__fold_result___4);

         _fx_catch_20: ;
            if (v_41) {
               _fx_free_N15C_form__cstmt_t(&v_41);
            }
            if (complex_if_1) {
               _fx_free_N15C_form__cstmt_t(&complex_if_1);
            }
            FX_CHECK_EXN(_fx_catch_21);
         }
         FX_COPY_PTR(__fold_result___4, &complex_if_0);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(complex_if_0, ccode_0, true, &v_40), _fx_catch_21);
         _fx_make_T2BLN15C_form__cstmt_t(false, v_40, &v_7);

      _fx_catch_21: ;
         if (v_40) {
            _fx_free_LN15C_form__cstmt_t(&v_40);
         }
         if (complex_if_0) {
            _fx_free_N15C_form__cstmt_t(&complex_if_0);
         }
         if (ifs_0) {
            _fx_free_LLN15C_form__cstmt_t(&ifs_0);
         }
         if (__fold_result___4) {
            _fx_free_N15C_form__cstmt_t(&__fold_result___4);
         }
         goto _fx_endmatch_4;
      }
   }
   _fx_LN15C_form__cstmt_t v_47 = 0;
   _fx_LN15C_form__cstmt_t v_48 = 0;
   FX_CALL(_fx_M10C_gen_codeFM6concatLN15C_form__cstmt_t1LLN15C_form__cstmt_t(all_cases_ccode_1, &v_47, 0), _fx_catch_24);
   if (v_47 == 0) {
      FX_COPY_PTR(ccode_0, &v_48);
   }
   else if (ccode_0 == 0) {
      FX_COPY_PTR(v_47, &v_48);
   }
   else {
      _fx_LN15C_form__cstmt_t v_49 = 0;
      _fx_LN15C_form__cstmt_t lstend_3 = 0;
      _fx_LN15C_form__cstmt_t lst_10 = v_47;
      for (; lst_10; lst_10 = lst_10->tl) {
         _fx_N15C_form__cstmt_t x_3 = lst_10->hd;
         _fx_LN15C_form__cstmt_t node_3 = 0;
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_3, 0, false, &node_3), _fx_catch_22);
         FX_LIST_APPEND(v_49, lstend_3, node_3);

      _fx_catch_22: ;
         FX_CHECK_EXN(_fx_catch_23);
      }
      _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_49, ccode_0, &v_48, 0);

   _fx_catch_23: ;
      if (v_49) {
         _fx_free_LN15C_form__cstmt_t(&v_49);
      }
   }
   FX_CHECK_EXN(_fx_catch_24);
   _fx_make_T2BLN15C_form__cstmt_t(em_label_used_0, v_48, &v_7);

_fx_catch_24: ;
   if (v_48) {
      _fx_free_LN15C_form__cstmt_t(&v_48);
   }
   if (v_47) {
      _fx_free_LN15C_form__cstmt_t(&v_47);
   }

_fx_endmatch_4: ;
   FX_CHECK_EXN(_fx_cleanup);
   bool em_label_used_1 = v_7.t0;
   FX_COPY_PTR(v_7.t1, &ccode_1);
   if (!em_label_used_1) {
      FX_COPY_PTR(ccode_1, &ccode_2);
   }
   else {
      FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&li_0, &end_loc_0, &v_8), _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_8, ccode_1, true, &ccode_2), _fx_cleanup);
   }
   if (!have_epilogues_0) {
      FX_COPY_PTR(ccode_2, fx_result);
   }
   else {
      FX_CALL(_fx_cons_LN14C_form__cexp_t(parent_lbl_0, 0, true, &v_9), _fx_cleanup);
      FX_CALL(
         _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g24C_form__std_FX_CHECK_EXN, v_9, _fx_g20C_gen_code__CTypVoid, &end_loc_0, &check_exn_0, 0), _fx_cleanup);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(check_exn_0, &v_10), _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_10, ccode_2, true, fx_result), _fx_cleanup);
   }

_fx_cleanup: ;
   FX_FREE_FP(&kexp2cexp_0);
   FX_FREE_STR(&v_0);
   FX_FREE_STR(&basename_0);
   FX_FREE_STR(&cname_0);
   _fx_free_R19C_form__cdeflabel_t(&v_1);
   _fx_free_N15C_form__cinfo_t(&v_2);
   _fx_free_T5BBBBLLN15C_form__cstmt_t(&__fold_result___0);
   _fx_free_T5BBBBLLN15C_form__cstmt_t(&v_3);
   if (all_cases_ccode_0) {
      _fx_free_LLN15C_form__cstmt_t(&all_cases_ccode_0);
   }
   if (parent_lbl_0) {
      _fx_free_N14C_form__cexp_t(&parent_lbl_0);
   }
   if (all_cases_ccode_1) {
      _fx_free_LLN15C_form__cstmt_t(&all_cases_ccode_1);
   }
   if (no_match_err_0) {
      _fx_free_N14C_form__cexp_t(&no_match_err_0);
   }
   if (v_4) {
      _fx_free_LN14C_form__cexp_t(&v_4);
   }
   if (throw_no_match_0) {
      _fx_free_N14C_form__cexp_t(&throw_no_match_0);
   }
   if (v_5) {
      _fx_free_N15C_form__cstmt_t(&v_5);
   }
   if (v_6) {
      _fx_free_LN15C_form__cstmt_t(&v_6);
   }
   _fx_free_T2BLN15C_form__cstmt_t(&v_7);
   if (ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&ccode_1);
   }
   if (ccode_2) {
      _fx_free_LN15C_form__cstmt_t(&ccode_2);
   }
   if (v_8) {
      _fx_free_N15C_form__cstmt_t(&v_8);
   }
   if (v_9) {
      _fx_free_LN14C_form__cexp_t(&v_9);
   }
   if (check_exn_0) {
      _fx_free_N14C_form__cexp_t(&check_exn_0);
   }
   if (v_10) {
      _fx_free_N15C_form__cstmt_t(&v_10);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t*
      fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t,
      _fx_free_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t,
      _fx_M10C_gen_codeFM13process_casesLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

static int
   _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_N14K_form__kexp_t_data_t* kexp_0,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti
      atom2cexp_0 = {0};
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t atom2cexp__0 = {0};
   _fx_FPLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t
      process_cases_0 = {0};
   _fx_FPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti
      process_for_0 = {0};
   _fx_T2N14K_form__ktyp_tR10Ast__loc_t v_0 = {0};
   _fx_N14K_form__ktyp_t ktyp_0 = 0;
   _fx_N14C_form__ctyp_t ctyp_0 = 0;
   _fx_N14C_form__cexp_t dummy_exp_0 = 0;
   _fx_T3BN14C_form__cexp_tLN15C_form__cstmt_t v_1 = {0};
   _fx_N14C_form__cexp_t result_exp_0 = 0;
   _fx_LN15C_form__cstmt_t ccode_1 = 0;
   _fx_Nt6option1N14C_form__cexp_t v_2 = {0};
   int fx_status = 0;
   FX_CALL(fx_check_stack(), _fx_cleanup);
   _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*)
         fx_fv;
   _fx_rLrR23C_gen_code__block_ctx_t block_stack_ref_1 = cv_0->t0;
   _fx_rNt10Hashset__t1R9Ast__id_t defined_syms_ref_1 = cv_0->t1;
   _fx_rLN15C_form__cstmt_t fwd_fdecls_ref_1 = cv_0->t2;
   _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t i2e_ref_1 = cv_0->t3;
   int_* km_idx_1 = &cv_0->t4;
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t8N14K_form__atom_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &atom2cexp_0);
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t4N14K_form__atom_tBLN15C_form__cstmt_tR10Ast__loc_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &atom2cexp__0);
   _fx_M10C_gen_codeFM7make_fpFPLN15C_form__cstmt_t19LT2LN14K_form__kexp_tN14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &process_cases_0);
   _fx_M10C_gen_codeFM7make_fpFPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &process_for_0);
   _fx_Nt10Hashset__t1R9Ast__id_t* defined_syms_0 = &defined_syms_ref_0->data;
   _fx_rNt6option1N14C_form__cexp_t* func_dstexp_r_0 = &func_dstexp_r_ref_0->data;
   _fx_LN15C_form__cstmt_t* glob_data_ccode_0 = &glob_data_ccode_ref_0->data;
   _fx_Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t* i2e_0 = &i2e_ref_0->data;
   _fx_LN15C_form__cstmt_t* module_cleanup_0 = &module_cleanup_ref_0->data;
   int_* return_used_0 = &return_used_ref_0->data;
   _fx_LN15C_form__cstmt_t* top_inline_ccode_0 = &top_inline_ccode_ref_0->data;
   FX_CALL(_fx_M6K_formFM12get_kexp_ctxT2N14K_form__ktyp_tR10Ast__loc_t1N14K_form__kexp_t(kexp_0, &v_0, 0), _fx_cleanup);
   FX_COPY_PTR(v_0.t0, &ktyp_0);
   _fx_R10Ast__loc_t kloc_0 = v_0.t1;
   FX_CALL(_fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_0, &kloc_0, &ctyp_0, 0),
      _fx_cleanup);
   FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &dummy_exp_0, 0), _fx_cleanup);
   int tag_0 = FX_REC_VARIANT_TAG(kexp_0);
   if (tag_0 == 1) {
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1); goto _fx_endmatch_49;
   }
   if (tag_0 == 2) {
      _fx_N15C_form__cstmt_t break_stmt_0 = 0;
      _fx_LN15C_form__cstmt_t v_3 = 0;
      FX_CALL(
         _fx_M10C_gen_codeFM15make_break_stmtN15C_form__cstmt_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &break_stmt_0, 0), _fx_catch_0);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(break_stmt_0, ccode_0, true, &v_3), _fx_catch_0);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_3, &v_1);

   _fx_catch_0: ;
      if (v_3) {
         _fx_free_LN15C_form__cstmt_t(&v_3);
      }
      if (break_stmt_0) {
         _fx_free_N15C_form__cstmt_t(&break_stmt_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 3) {
      _fx_N15C_form__cstmt_t continue_stmt_0 = 0;
      _fx_LN15C_form__cstmt_t v_4 = 0;
      FX_CALL(
         _fx_M10C_gen_codeFM18make_continue_stmtN15C_form__cstmt_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &continue_stmt_0, 0), _fx_catch_1);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(continue_stmt_0, ccode_0, true, &v_4), _fx_catch_1);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_4, &v_1);

   _fx_catch_1: ;
      if (v_4) {
         _fx_free_LN15C_form__cstmt_t(&v_4);
      }
      if (continue_stmt_0) {
         _fx_free_N15C_form__cstmt_t(&continue_stmt_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 4) {
      _fx_rR23C_gen_code__block_ctx_t bctx_0 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_5 = {0};
      _fx_LN15C_form__cstmt_t ccode_2 = 0;
      _fx_N14C_form__cexp_t lbl_0 = 0;
      _fx_LN14C_form__cexp_t v_6 = 0;
      _fx_N14C_form__cexp_t v_7 = 0;
      _fx_N15C_form__cstmt_t ret_exp_0 = 0;
      _fx_LN15C_form__cstmt_t v_8 = 0;
      _fx_Nt6option1N14K_form__atom_t* a_opt_0 = &kexp_0->u.KExpReturn.t0;
      FX_CALL(
         _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &bctx_0, 0), _fx_catch_3);
      bctx_0->data.bctx_return_used = bctx_0->data.bctx_return_used + 1;
      *return_used_0 = *return_used_0 + 1;
      _fx_copy_Nt6option1N14C_form__cexp_t(&(*func_dstexp_r_0)->data, &v_5);
      if (v_5.tag == 2) {
         if (a_opt_0->tag == 2) {
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_9 = {0};
            _fx_N14C_form__cexp_t e_0 = 0;
            _fx_LN15C_form__cstmt_t ccode_3 = 0;
            _fx_N14C_form__ctyp_t ctyp_1 = 0;
            FX_CALL(
               atom2cexp_0.fp(&a_opt_0->u.Some, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                  i2e_ref_0, km_idx_0, &v_9, atom2cexp_0.fcv), _fx_catch_2);
            FX_COPY_PTR(v_9.t0, &e_0);
            FX_COPY_PTR(v_9.t1, &ccode_3);
            FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(e_0, &ctyp_1, 0), _fx_catch_2);
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  e_0, v_5.u.Some, ctyp_1, ccode_3, &kloc_0, &ccode_2, 0), _fx_catch_2);

         _fx_catch_2: ;
            if (ctyp_1) {
               _fx_free_N14C_form__ctyp_t(&ctyp_1);
            }
            if (ccode_3) {
               _fx_free_LN15C_form__cstmt_t(&ccode_3);
            }
            if (e_0) {
               _fx_free_N14C_form__cexp_t(&e_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_9);
            goto _fx_endmatch_0;
         }
      }
      FX_COPY_PTR(ccode_0, &ccode_2);

   _fx_endmatch_0: ;
      FX_CHECK_EXN(_fx_catch_3);
      FX_CALL(
         _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &lbl_0, 0), _fx_catch_3);
      _fx_R9Ast__id_t v_10;
      fx_str_t slit_0 = FX_MAKE_STR("FX_RETURN");
      FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_0, &v_10, 0), _fx_catch_3);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_0, 0, true, &v_6), _fx_catch_3);
      FX_CALL(
         _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_10, v_6,
            _fx_g20C_gen_code__CTypVoid, &kloc_0, &v_7, 0), _fx_catch_3);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_7, &ret_exp_0), _fx_catch_3);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(ret_exp_0, ccode_2, true, &v_8), _fx_catch_3);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_8, &v_1);

   _fx_catch_3: ;
      if (v_8) {
         _fx_free_LN15C_form__cstmt_t(&v_8);
      }
      if (ret_exp_0) {
         _fx_free_N15C_form__cstmt_t(&ret_exp_0);
      }
      if (v_7) {
         _fx_free_N14C_form__cexp_t(&v_7);
      }
      if (v_6) {
         _fx_free_LN14C_form__cexp_t(&v_6);
      }
      if (lbl_0) {
         _fx_free_N14C_form__cexp_t(&lbl_0);
      }
      if (ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&ccode_2);
      }
      _fx_free_Nt6option1N14C_form__cexp_t(&v_5);
      if (bctx_0) {
         _fx_free_rR23C_gen_code__block_ctx_t(&bctx_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 5) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_11 = {0};
      _fx_N14C_form__cexp_t e_1 = 0;
      _fx_LN15C_form__cstmt_t ccode_4 = 0;
      _fx_N14C_form__cexp_t e_2 = 0;
      FX_CALL(
         atom2cexp_0.fp(&kexp_0->u.KExpAtom.t0, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
            i2e_ref_0, km_idx_0, &v_11, atom2cexp_0.fcv), _fx_catch_4);
      FX_COPY_PTR(v_11.t0, &e_1);
      FX_COPY_PTR(v_11.t1, &ccode_4);
      FX_CALL(_fx_M10C_gen_codeFM7fix_nilN14C_form__cexp_t2N14C_form__cexp_tN14K_form__ktyp_t(e_1, ktyp_0, &e_2, 0),
         _fx_catch_4);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, e_2, ccode_4, &v_1);

   _fx_catch_4: ;
      if (e_2) {
         _fx_free_N14C_form__cexp_t(&e_2);
      }
      if (ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&ccode_4);
      }
      if (e_1) {
         _fx_free_N14C_form__cexp_t(&e_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_11);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 6) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_12 = {0};
      _fx_N14C_form__cexp_t ce1_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_5 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_13 = {0};
      _fx_N14C_form__cexp_t ce2_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_6 = 0;
      _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_0 = &kexp_0->u.KExpBinary;
      _fx_N14K_form__atom_t* a2_0 = &vcase_0->t2;
      _fx_N14K_form__atom_t* a1_0 = &vcase_0->t1;
      _fx_N13Ast__binary_t bop_0 = vcase_0->t0;
      int tag_1 = FX_REC_VARIANT_TAG(bop_0);
      _fx_Ta2B v_14;
      bool res_0;
      if (tag_1 == 4) {
         res_0 = true;
      }
      else if (tag_1 == 6) {
         res_0 = true;
      }
      else {
         res_0 = false;
      }
      FX_CHECK_EXN(_fx_catch_23);
      if (res_0) {
         _fx_N14K_form__ktyp_t v_15 = 0;
         _fx_N14K_form__ktyp_t v_16 = 0;
         FX_CALL(_fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(a1_0, &kloc_0, &v_15, 0),
            _fx_catch_5);
         bool f1_0;
         FX_CALL(_fx_M6K_formFM15is_ktyp_integerB2N14K_form__ktyp_tB(v_15, true, &f1_0, 0), _fx_catch_5);
         FX_CALL(_fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(a2_0, &kloc_0, &v_16, 0),
            _fx_catch_5);
         bool f2_0;
         FX_CALL(_fx_M6K_formFM15is_ktyp_integerB2N14K_form__ktyp_tB(v_16, true, &f2_0, 0), _fx_catch_5);
         bool nonlit_0;
         if (a2_0->tag == 1) {
            nonlit_0 = true;
         }
         else {
            nonlit_0 = false;
         }
         FX_CHECK_EXN(_fx_catch_5);
         bool t_0;
         if (f1_0) {
            t_0 = f2_0;
         }
         else {
            t_0 = false;
         }
         bool t_1;
         if (f2_0) {
            t_1 = nonlit_0;
         }
         else {
            t_1 = false;
         }
         _fx_Ta2B tup_0 = { t_0, t_1 };
         v_14 = tup_0;

      _fx_catch_5: ;
         if (v_16) {
            _fx_free_N14K_form__ktyp_t(&v_16);
         }
         if (v_15) {
            _fx_free_N14K_form__ktyp_t(&v_15);
         }
         goto _fx_endmatch_1;
      }
      _fx_Ta2B tup_1 = { false, false };
      v_14 = tup_1;

   _fx_endmatch_1: ;
      FX_CHECK_EXN(_fx_catch_23);
      bool int_divmod_operands_0 = v_14.t0;
      bool save_and_check_0 = v_14.t1;
      FX_CALL(
         atom2cexp_0.fp(a1_0, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
            &v_12, atom2cexp_0.fcv), _fx_catch_23);
      FX_COPY_PTR(v_12.t0, &ce1_0);
      FX_COPY_PTR(v_12.t1, &ccode_5);
      FX_CALL(atom2cexp__0.fp(a2_0, save_and_check_0, ccode_5, &kloc_0, &v_13, atom2cexp__0.fcv), _fx_catch_23);
      FX_COPY_PTR(v_13.t0, &ce2_0);
      FX_COPY_PTR(v_13.t1, &ccode_6);
      int tag_2 = FX_REC_VARIANT_TAG(bop_0);
      if (tag_2 == 7) {
         _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t v_17 = {0};
         _fx_N14C_form__cexp_t ce1_1 = 0;
         _fx_N14C_form__cexp_t ce2_1 = 0;
         _fx_N14C_form__ctyp_t rtyp_0 = 0;
         _fx_LN14C_form__cexp_t v_18 = 0;
         _fx_N14C_form__cexp_t e_3 = 0;
         _fx_N14C_form__cexp_t e_4 = 0;
         int tag_3 = FX_REC_VARIANT_TAG(ctyp_0);
         if (tag_3 == 7) {
            if (ctyp_0->u.CTypFloat == 64) {
               _fx_R9Ast__id_t v_19;
               fx_str_t slit_1 = FX_MAKE_STR("pow");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_1, &v_19, 0), _fx_catch_6);
               _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(false, ce1_0, ce2_0, ctyp_0, &v_19,
                  &v_17);

            _fx_catch_6: ;
               goto _fx_endmatch_2;
            }
         }
         if (tag_3 == 7) {
            _fx_R9Ast__id_t v_20;
            fx_str_t slit_2 = FX_MAKE_STR("powf");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_2, &v_20, 0), _fx_catch_7);
            _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(false, ce1_0, ce2_0, ctyp_0, &v_20,
               &v_17);

         _fx_catch_7: ;
            goto _fx_endmatch_2;
         }
         _fx_N14C_form__ctyp_t v_21 = 0;
         _fx_N14C_form__cexp_t ce1_2 = 0;
         _fx_N14C_form__ctyp_t v_22 = 0;
         _fx_N14C_form__cexp_t ce2_2 = 0;
         _fx_N14C_form__ctyp_t v_23 = 0;
         FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(64, &v_21), _fx_catch_8);
         FX_CALL(
            _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(ce1_0, v_21, &kloc_0,
               &ce1_2), _fx_catch_8);
         FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(64, &v_22), _fx_catch_8);
         FX_CALL(
            _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(ce2_0, v_22, &kloc_0,
               &ce2_2), _fx_catch_8);
         FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(64, &v_23), _fx_catch_8);
         _fx_R9Ast__id_t v_24;
         fx_str_t slit_3 = FX_MAKE_STR("pow");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_3, &v_24, 0), _fx_catch_8);
         _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(true, ce1_2, ce2_2, v_23, &v_24, &v_17);

      _fx_catch_8: ;
         if (v_23) {
            _fx_free_N14C_form__ctyp_t(&v_23);
         }
         if (ce2_2) {
            _fx_free_N14C_form__cexp_t(&ce2_2);
         }
         if (v_22) {
            _fx_free_N14C_form__ctyp_t(&v_22);
         }
         if (ce1_2) {
            _fx_free_N14C_form__cexp_t(&ce1_2);
         }
         if (v_21) {
            _fx_free_N14C_form__ctyp_t(&v_21);
         }

      _fx_endmatch_2: ;
         FX_CHECK_EXN(_fx_catch_9);
         bool need_cast_0 = v_17.t0;
         FX_COPY_PTR(v_17.t1, &ce1_1);
         FX_COPY_PTR(v_17.t2, &ce2_1);
         FX_COPY_PTR(v_17.t3, &rtyp_0);
         _fx_R9Ast__id_t f_0 = v_17.t4;
         FX_CALL(_fx_cons_LN14C_form__cexp_t(ce2_1, 0, true, &v_18), _fx_catch_9);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(ce1_1, v_18, false, &v_18), _fx_catch_9);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&f_0, v_18,
               rtyp_0, &kloc_0, &e_3, 0), _fx_catch_9);
         if (need_cast_0) {
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(e_3, ctyp_0, &kloc_0,
                  &e_4), _fx_catch_9);
         }
         else {
            FX_COPY_PTR(e_3, &e_4);
         }
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, e_4, ccode_6, &v_1);

      _fx_catch_9: ;
         if (e_4) {
            _fx_free_N14C_form__cexp_t(&e_4);
         }
         if (e_3) {
            _fx_free_N14C_form__cexp_t(&e_3);
         }
         if (v_18) {
            _fx_free_LN14C_form__cexp_t(&v_18);
         }
         if (rtyp_0) {
            _fx_free_N14C_form__ctyp_t(&rtyp_0);
         }
         if (ce2_1) {
            _fx_free_N14C_form__cexp_t(&ce2_1);
         }
         if (ce1_1) {
            _fx_free_N14C_form__cexp_t(&ce1_1);
         }
         _fx_free_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(&v_17);
      }
      else if (tag_2 == 4) {
         _fx_N14C_form__cexp_t lbl_1 = 0;
         _fx_LN14C_form__cexp_t v_25 = 0;
         _fx_N14C_form__cexp_t chk_denom_0 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_26 = {0};
         _fx_N14C_form__cexp_t div_exp_0 = 0;
         _fx_N15C_form__cstmt_t v_27 = 0;
         _fx_LN15C_form__cstmt_t v_28 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_29 = {0};
         _fx_N14C_form__cexp_t v_30 = 0;
         if (save_and_check_0) {
            FX_CALL(
               _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0,
                  block_stack_ref_0, &lbl_1, 0), _fx_catch_10);
            _fx_R9Ast__id_t v_31;
            fx_str_t slit_4 = FX_MAKE_STR("FX_CHECK_DIV_BY_ZERO");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_4, &v_31, 0), _fx_catch_10);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_1, 0, true, &v_25), _fx_catch_10);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce2_0, v_25, false, &v_25), _fx_catch_10);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_31,
                  v_25, _fx_g20C_gen_code__CTypVoid, &kloc_0, &chk_denom_0, 0), _fx_catch_10);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_26);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g18C_gen_code__COpDiv, ce1_0, ce2_0, &v_26, &div_exp_0), _fx_catch_10);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(chk_denom_0, &v_27), _fx_catch_10);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_27, ccode_6, true, &v_28), _fx_catch_10);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, div_exp_0, v_28, &v_1);
         }
         else {
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_29);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g18C_gen_code__COpDiv, ce1_0, ce2_0, &v_29, &v_30), _fx_catch_10);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_30, ccode_6, &v_1);
         }

      _fx_catch_10: ;
         if (v_30) {
            _fx_free_N14C_form__cexp_t(&v_30);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_29);
         if (v_28) {
            _fx_free_LN15C_form__cstmt_t(&v_28);
         }
         if (v_27) {
            _fx_free_N15C_form__cstmt_t(&v_27);
         }
         if (div_exp_0) {
            _fx_free_N14C_form__cexp_t(&div_exp_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_26);
         if (chk_denom_0) {
            _fx_free_N14C_form__cexp_t(&chk_denom_0);
         }
         if (v_25) {
            _fx_free_LN14C_form__cexp_t(&v_25);
         }
         if (lbl_1) {
            _fx_free_N14C_form__cexp_t(&lbl_1);
         }
      }
      else if (tag_2 == 6) {
         _fx_N14C_form__cexp_t lbl_2 = 0;
         _fx_LN14C_form__cexp_t v_32 = 0;
         _fx_N14C_form__cexp_t chk_denom_1 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_33 = {0};
         _fx_N14C_form__cexp_t mod_exp_0 = 0;
         _fx_N15C_form__cstmt_t v_34 = 0;
         _fx_LN15C_form__cstmt_t v_35 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_36 = {0};
         _fx_N14C_form__cexp_t v_37 = 0;
         _fx_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t v_38 = {0};
         _fx_N14C_form__cexp_t ce1_3 = 0;
         _fx_N14C_form__cexp_t ce2_3 = 0;
         _fx_N14C_form__ctyp_t rtyp_1 = 0;
         _fx_LN14C_form__cexp_t v_39 = 0;
         _fx_N14C_form__cexp_t e_5 = 0;
         _fx_N14C_form__cexp_t e_6 = 0;
         if (save_and_check_0) {
            FX_CALL(
               _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0,
                  block_stack_ref_0, &lbl_2, 0), _fx_catch_14);
            _fx_R9Ast__id_t v_40;
            fx_str_t slit_5 = FX_MAKE_STR("FX_CHECK_DIV_BY_ZERO");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_5, &v_40, 0), _fx_catch_14);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_2, 0, true, &v_32), _fx_catch_14);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce2_0, v_32, false, &v_32), _fx_catch_14);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_40,
                  v_32, _fx_g20C_gen_code__CTypVoid, &kloc_0, &chk_denom_1, 0), _fx_catch_14);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_33);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g18C_gen_code__COpMod, ce1_0, ce2_0, &v_33, &mod_exp_0), _fx_catch_14);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(chk_denom_1, &v_34), _fx_catch_14);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_34, ccode_6, true, &v_35), _fx_catch_14);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, mod_exp_0, v_35, &v_1);
         }
         else if (int_divmod_operands_0) {
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_36);
            FX_CALL(
               _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g18C_gen_code__COpMod, ce1_0, ce2_0, &v_36, &v_37), _fx_catch_14);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_37, ccode_6, &v_1);
         }
         else {
            int tag_4 = FX_REC_VARIANT_TAG(ctyp_0);
            bool res_1;
            if (tag_4 == 1) {
               res_1 = true; goto _fx_endmatch_3;
            }
            if (tag_4 == 7) {
               if (ctyp_0->u.CTypFloat == 32) {
                  res_1 = true; goto _fx_endmatch_3;
               }
            }
            res_1 = false;

         _fx_endmatch_3: ;
            FX_CHECK_EXN(_fx_catch_14);
            if (res_1) {
               _fx_R9Ast__id_t v_41;
               fx_str_t slit_6 = FX_MAKE_STR("fmodf");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_6, &v_41, 0), _fx_catch_11);
               _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(false, ce1_0, ce2_0, ctyp_0, &v_41,
                  &v_38);

            _fx_catch_11: ;
               goto _fx_endmatch_4;
            }
            if (tag_4 == 7) {
               if (ctyp_0->u.CTypFloat == 64) {
                  _fx_R9Ast__id_t v_42;
                  fx_str_t slit_7 = FX_MAKE_STR("fmod");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_7, &v_42, 0), _fx_catch_12);
                  _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(false, ce1_0, ce2_0, ctyp_0, &v_42,
                     &v_38);

               _fx_catch_12: ;
                  goto _fx_endmatch_4;
               }
            }
            _fx_N14C_form__ctyp_t v_43 = 0;
            _fx_N14C_form__cexp_t ce1_4 = 0;
            _fx_N14C_form__ctyp_t v_44 = 0;
            _fx_N14C_form__cexp_t ce2_4 = 0;
            _fx_N14C_form__ctyp_t v_45 = 0;
            FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(64, &v_43), _fx_catch_13);
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(ce1_0, v_43, &kloc_0,
                  &ce1_4), _fx_catch_13);
            FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(64, &v_44), _fx_catch_13);
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(ce2_0, v_44, &kloc_0,
                  &ce2_4), _fx_catch_13);
            FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(64, &v_45), _fx_catch_13);
            _fx_R9Ast__id_t v_46;
            fx_str_t slit_8 = FX_MAKE_STR("fmod");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_8, &v_46, 0), _fx_catch_13);
            _fx_make_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(true, ce1_4, ce2_4, v_45, &v_46, &v_38);

         _fx_catch_13: ;
            if (v_45) {
               _fx_free_N14C_form__ctyp_t(&v_45);
            }
            if (ce2_4) {
               _fx_free_N14C_form__cexp_t(&ce2_4);
            }
            if (v_44) {
               _fx_free_N14C_form__ctyp_t(&v_44);
            }
            if (ce1_4) {
               _fx_free_N14C_form__cexp_t(&ce1_4);
            }
            if (v_43) {
               _fx_free_N14C_form__ctyp_t(&v_43);
            }

         _fx_endmatch_4: ;
            FX_CHECK_EXN(_fx_catch_14);
            bool need_cast_1 = v_38.t0;
            FX_COPY_PTR(v_38.t1, &ce1_3);
            FX_COPY_PTR(v_38.t2, &ce2_3);
            FX_COPY_PTR(v_38.t3, &rtyp_1);
            _fx_R9Ast__id_t f_1 = v_38.t4;
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce2_3, 0, true, &v_39), _fx_catch_14);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce1_3, v_39, false, &v_39), _fx_catch_14);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&f_1, v_39,
                  rtyp_1, &kloc_0, &e_5, 0), _fx_catch_14);
            if (need_cast_1) {
               FX_CALL(
                  _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(e_5, ctyp_0, &kloc_0,
                     &e_6), _fx_catch_14);
            }
            else {
               FX_COPY_PTR(e_5, &e_6);
            }
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, e_6, ccode_6, &v_1);
         }

      _fx_catch_14: ;
         if (e_6) {
            _fx_free_N14C_form__cexp_t(&e_6);
         }
         if (e_5) {
            _fx_free_N14C_form__cexp_t(&e_5);
         }
         if (v_39) {
            _fx_free_LN14C_form__cexp_t(&v_39);
         }
         if (rtyp_1) {
            _fx_free_N14C_form__ctyp_t(&rtyp_1);
         }
         if (ce2_3) {
            _fx_free_N14C_form__cexp_t(&ce2_3);
         }
         if (ce1_3) {
            _fx_free_N14C_form__cexp_t(&ce1_3);
         }
         _fx_free_T5BN14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tR9Ast__id_t(&v_38);
         if (v_37) {
            _fx_free_N14C_form__cexp_t(&v_37);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_36);
         if (v_35) {
            _fx_free_LN15C_form__cstmt_t(&v_35);
         }
         if (v_34) {
            _fx_free_N15C_form__cstmt_t(&v_34);
         }
         if (mod_exp_0) {
            _fx_free_N14C_form__cexp_t(&mod_exp_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_33);
         if (chk_denom_1) {
            _fx_free_N14C_form__cexp_t(&chk_denom_1);
         }
         if (v_32) {
            _fx_free_LN14C_form__cexp_t(&v_32);
         }
         if (lbl_2) {
            _fx_free_N14C_form__cexp_t(&lbl_2);
         }
      }
      else if (tag_2 == 26) {
         _fx_Nt6option1N14C_form__cexp_t v_47 = {0};
         _fx_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t v_48 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_49 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_50 = {0};
         _fx_N14C_form__cexp_t l_exp_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_7 = 0;
         _fx_R9Ast__id_t a2_id_0;
         if (a2_0->tag == 1) {
            _fx_R9Ast__id_t* i_0 = &a2_0->u.AtomId;
            bool res_2;
            FX_CALL(_fx_M10C_gen_codeFM3memB2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(u1vals_0, i_0, &res_2, 0), _fx_catch_15);
            if (res_2) {
               a2_id_0 = *i_0; goto _fx_endmatch_5;
            }
         }
         a2_id_0 = _fx_g9Ast__noid;

      _fx_endmatch_5: ;
         FX_CHECK_EXN(_fx_catch_15);
         _fx_R9Ast__id_t ce2_id_0;
         if (FX_REC_VARIANT_TAG(ce2_0) == 1) {
            ce2_id_0 = ce2_0->u.CExpIdent.t0;
         }
         else {
            ce2_id_0 = _fx_g9Ast__noid;
         }
         FX_CHECK_EXN(_fx_catch_15);
         _fx_copy_Nt6option1N14C_form__cexp_t(&dstexp_r_0->data, &v_47);
         bool res_3;
         FX_CALL(_fx_M10C_gen_codeFM6isnoneB1Nt6option1N14C_form__cexp_t(&v_47, &res_3, 0), _fx_catch_15);
         bool t_2;
         if (res_3) {
            FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&a2_id_0, &_fx_g9Ast__noid, &t_2, 0), _fx_catch_15);
         }
         else {
            t_2 = false;
         }
         bool t_3;
         if (t_2) {
            FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&ce2_id_0, &_fx_g9Ast__noid, &t_3, 0), _fx_catch_15);
         }
         else {
            t_3 = false;
         }
         if (t_3) {
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(ce2_0, 0, &v_49);
            _fx_make_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t(true, &v_49, &v_48);
         }
         else {
            fx_str_t slit_9 = FX_MAKE_STR("lst");
            FX_CALL(
               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                  dstexp_r_0, &slit_9, ctyp_0, 0, &kloc_0, block_stack_ref_0, km_idx_0, &v_50, 0), _fx_catch_15);
            _fx_make_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t(false, &v_50, &v_48);
         }
         bool reuse_ce2_0 = v_48.t0;
         FX_COPY_PTR(v_48.t1.t0, &l_exp_0);
         FX_CALL(
            _fx_M10C_gen_codeFM14make_cons_callLN15C_form__cstmt_t7N14C_form__cexp_tN14C_form__cexp_tBN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               ce1_0, ce2_0, !reuse_ce2_0, l_exp_0, ccode_6, &kloc_0, block_stack_ref_0, &ccode_7, 0), _fx_catch_15);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, l_exp_0, ccode_7, &v_1);

      _fx_catch_15: ;
         if (ccode_7) {
            _fx_free_LN15C_form__cstmt_t(&ccode_7);
         }
         if (l_exp_0) {
            _fx_free_N14C_form__cexp_t(&l_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_50);
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_49);
         _fx_free_T2BT2N14C_form__cexp_tLN15C_form__cstmt_t(&v_48);
         _fx_free_Nt6option1N14C_form__cexp_t(&v_47);
      }
      else {
         _fx_T2N17C_form__cbinary_tN14C_form__ctyp_t v_51 = {0};
         _fx_N14C_form__ctyp_t bop_ctyp_0 = 0;
         _fx_N14C_form__ctyp_t v_52 = 0;
         int tag_5 = FX_REC_VARIANT_TAG(bop_0);
         if (tag_5 == 1) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g18C_gen_code__COpAdd, ctyp_0, &v_51); goto _fx_endmatch_6;
         }
         if (tag_5 == 2) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g18C_gen_code__COpSub, ctyp_0, &v_51); goto _fx_endmatch_6;
         }
         if (tag_5 == 3) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g18C_gen_code__COpMul, ctyp_0, &v_51); goto _fx_endmatch_6;
         }
         if (tag_5 == 4) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g18C_gen_code__COpDiv, ctyp_0, &v_51); goto _fx_endmatch_6;
         }
         if (tag_5 == 8) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g24C_gen_code__COpShiftLeft, ctyp_0, &v_51);
            goto _fx_endmatch_6;
         }
         if (tag_5 == 9) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g25C_gen_code__COpShiftRight, ctyp_0, &v_51);
            goto _fx_endmatch_6;
         }
         if (tag_5 == 16) {
            _fx_N14C_form__ctyp_t v_53 = 0;
            if (FX_REC_VARIANT_TAG(ktyp_0) == 8) {
               FX_COPY_PTR(_fx_g19C_gen_code__CTypInt, &v_53);
            }
            else {
               FX_COPY_PTR(ctyp_0, &v_53);
            }
            FX_CHECK_EXN(_fx_catch_16);
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g25C_gen_code__COpBitwiseAnd, v_53, &v_51);

         _fx_catch_16: ;
            if (v_53) {
               _fx_free_N14C_form__ctyp_t(&v_53);
            }
            goto _fx_endmatch_6;
         }
         if (tag_5 == 18) {
            _fx_N14C_form__ctyp_t v_54 = 0;
            if (FX_REC_VARIANT_TAG(ktyp_0) == 8) {
               FX_COPY_PTR(_fx_g19C_gen_code__CTypInt, &v_54);
            }
            else {
               FX_COPY_PTR(ctyp_0, &v_54);
            }
            FX_CHECK_EXN(_fx_catch_17);
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g24C_gen_code__COpBitwiseOr, v_54, &v_51);

         _fx_catch_17: ;
            if (v_54) {
               _fx_free_N14C_form__ctyp_t(&v_54);
            }
            goto _fx_endmatch_6;
         }
         if (tag_5 == 20) {
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&_fx_g25C_gen_code__COpBitwiseXor, ctyp_0, &v_51);
            goto _fx_endmatch_6;
         }
         if (tag_5 == 21) {
            _fx_N17C_form__cbinary_t v_55;
            _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&bop_0->u.OpCmp, &v_55);
            _fx_make_T2N17C_form__cbinary_tN14C_form__ctyp_t(&v_55, ctyp_0, &v_51);
            goto _fx_endmatch_6;
         }
         bool res_4;
         if (tag_5 == 26) {
            res_4 = true;
         }
         else if (tag_5 == 7) {
            res_4 = true;
         }
         else if (tag_5 == 6) {
            res_4 = true;
         }
         else if (tag_5 == 17) {
            res_4 = true;
         }
         else if (tag_5 == 19) {
            res_4 = true;
         }
         else if (tag_5 == 23) {
            res_4 = true;
         }
         else if (tag_5 == 24) {
            res_4 = true;
         }
         else if (tag_5 == 10) {
            res_4 = true;
         }
         else if (tag_5 == 11) {
            res_4 = true;
         }
         else if (tag_5 == 12) {
            res_4 = true;
         }
         else if (tag_5 == 13) {
            res_4 = true;
         }
         else if (tag_5 == 14) {
            res_4 = true;
         }
         else if (tag_5 == 15) {
            res_4 = true;
         }
         else if (tag_5 == 22) {
            res_4 = true;
         }
         else if (tag_5 == 25) {
            res_4 = true;
         }
         else if (tag_5 == 5) {
            res_4 = true;
         }
         else if (tag_5 == 27) {
            res_4 = true;
         }
         else {
            res_4 = false;
         }
         FX_CHECK_EXN(_fx_catch_22);
         if (res_4) {
            fx_str_t v_56 = {0};
            fx_str_t v_57 = {0};
            fx_exn_t v_58 = {0};
            FX_CALL(_fx_M3AstFM6stringS1N13Ast__binary_t(bop_0, &v_56, 0), _fx_catch_18);
            fx_str_t slit_10 = FX_MAKE_STR("cgen: unsupported op \'");
            fx_str_t slit_11 = FX_MAKE_STR("\' at this stage");
            {
               const fx_str_t strs_0[] = { slit_10, v_56, slit_11 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_0, 3, &v_57), _fx_catch_18);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_57, &v_58, 0), _fx_catch_18);
            FX_THROW(&v_58, false, _fx_catch_18);

         _fx_catch_18: ;
            fx_free_exn(&v_58);
            FX_FREE_STR(&v_57);
            FX_FREE_STR(&v_56);
            goto _fx_endmatch_6;
         }
         FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_22);

      _fx_endmatch_6: ;
         FX_CHECK_EXN(_fx_catch_22);
         _fx_N17C_form__cbinary_t c_bop_0 = v_51.t0;
         FX_COPY_PTR(v_51.t1, &bop_ctyp_0);
         FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(ce1_0, &v_52, 0), _fx_catch_22);
         if (c_bop_0.tag == 13) {
            if (FX_REC_VARIANT_TAG(v_52) == 12) {
               if (c_bop_0.u.COpCmp.tag == 1) {
                  _fx_N14C_form__cexp_t v_59 = 0;
                  _fx_N14C_form__cexp_t v_60 = 0;
                  _fx_LN14C_form__cexp_t v_61 = 0;
                  _fx_N14C_form__cexp_t call_streq_0 = 0;
                  _fx_R9Ast__id_t f_exp_0;
                  fx_str_t slit_12 = FX_MAKE_STR("fx_streq");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_12, &f_exp_0, 0), _fx_catch_19);
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(ce1_0, &v_59, 0), _fx_catch_19);
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(ce2_0, &v_60, 0), _fx_catch_19);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_60, 0, true, &v_61), _fx_catch_19);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_59, v_61, false, &v_61), _fx_catch_19);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &f_exp_0, v_61, _fx_g20C_gen_code__CTypBool, &kloc_0, &call_streq_0, 0), _fx_catch_19);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, call_streq_0, ccode_6, &v_1);

               _fx_catch_19: ;
                  if (call_streq_0) {
                     _fx_free_N14C_form__cexp_t(&call_streq_0);
                  }
                  if (v_61) {
                     _fx_free_LN14C_form__cexp_t(&v_61);
                  }
                  if (v_60) {
                     _fx_free_N14C_form__cexp_t(&v_60);
                  }
                  if (v_59) {
                     _fx_free_N14C_form__cexp_t(&v_59);
                  }
                  goto _fx_endmatch_7;
               }
            }
         }
         if (c_bop_0.tag == 1) {
            if (FX_REC_VARIANT_TAG(v_52) == 20) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_62 = {0};
               _fx_N14C_form__cexp_t dst_exp_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_8 = 0;
               _fx_N14C_form__cexp_t v_63 = 0;
               _fx_N14C_form__cexp_t v_64 = 0;
               _fx_N14C_form__cexp_t v_65 = 0;
               _fx_LN14C_form__cexp_t v_66 = 0;
               _fx_N14C_form__cexp_t call_concat_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_9 = 0;
               fx_str_t slit_13 = FX_MAKE_STR("v");
               FX_CALL(
                  _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                     dstexp_r_0, &slit_13, ctyp_0, ccode_6, &kloc_0, block_stack_ref_0, km_idx_0, &v_62, 0), _fx_catch_20);
               FX_COPY_PTR(v_62.t0, &dst_exp_0);
               FX_COPY_PTR(v_62.t1, &ccode_8);
               _fx_R9Ast__id_t v_67;
               fx_str_t slit_14 = FX_MAKE_STR("fx_rrb_concat");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_14, &v_67, 0), _fx_catch_20);
               FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(ce1_0, &v_63, 0), _fx_catch_20);
               FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(ce2_0, &v_64, 0), _fx_catch_20);
               FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_0, &v_65, 0), _fx_catch_20);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_65, 0, true, &v_66), _fx_catch_20);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_64, v_66, false, &v_66), _fx_catch_20);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_63, v_66, false, &v_66), _fx_catch_20);
               FX_CALL(
                  _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_67,
                     v_66, _fx_g20C_gen_code__CTypCInt, &kloc_0, &call_concat_0, 0), _fx_catch_20);
               FX_CALL(
                  _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     call_concat_0, ccode_8, &kloc_0, block_stack_ref_0, &ccode_9, 0), _fx_catch_20);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_0, ccode_9, &v_1);

            _fx_catch_20: ;
               if (ccode_9) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_9);
               }
               if (call_concat_0) {
                  _fx_free_N14C_form__cexp_t(&call_concat_0);
               }
               if (v_66) {
                  _fx_free_LN14C_form__cexp_t(&v_66);
               }
               if (v_65) {
                  _fx_free_N14C_form__cexp_t(&v_65);
               }
               if (v_64) {
                  _fx_free_N14C_form__cexp_t(&v_64);
               }
               if (v_63) {
                  _fx_free_N14C_form__cexp_t(&v_63);
               }
               if (ccode_8) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_8);
               }
               if (dst_exp_0) {
                  _fx_free_N14C_form__cexp_t(&dst_exp_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_62);
               goto _fx_endmatch_7;
            }
         }
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_68 = {0};
         _fx_N14C_form__cexp_t res_5 = 0;
         _fx_N14C_form__cexp_t res_6 = 0;
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(bop_ctyp_0, &kloc_0, &v_68);
         FX_CALL(
            _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               &c_bop_0, ce1_0, ce2_0, &v_68, &res_5), _fx_catch_21);
         bool v_69;
         FX_CALL(_fx_M10C_gen_codeFM15__eq_variants__B2N14C_form__ctyp_tN14C_form__ctyp_t(ctyp_0, bop_ctyp_0, &v_69, 0),
            _fx_catch_21);
         if (v_69) {
            FX_COPY_PTR(res_5, &res_6);
         }
         else {
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(res_5, ctyp_0, &kloc_0,
                  &res_6), _fx_catch_21);
         }
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, res_6, ccode_6, &v_1);

      _fx_catch_21: ;
         if (res_6) {
            _fx_free_N14C_form__cexp_t(&res_6);
         }
         if (res_5) {
            _fx_free_N14C_form__cexp_t(&res_5);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_68);

      _fx_endmatch_7: ;
         FX_CHECK_EXN(_fx_catch_22);

      _fx_catch_22: ;
         if (v_52) {
            _fx_free_N14C_form__ctyp_t(&v_52);
         }
         if (bop_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&bop_ctyp_0);
         }
         _fx_free_T2N17C_form__cbinary_tN14C_form__ctyp_t(&v_51);
      }
      FX_CHECK_EXN(_fx_catch_23);

   _fx_catch_23: ;
      if (ccode_6) {
         _fx_free_LN15C_form__cstmt_t(&ccode_6);
      }
      if (ce2_0) {
         _fx_free_N14C_form__cexp_t(&ce2_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_13);
      if (ccode_5) {
         _fx_free_LN15C_form__cstmt_t(&ccode_5);
      }
      if (ce1_0) {
         _fx_free_N14C_form__cexp_t(&ce1_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_12);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 7) {
      _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_1 = &kexp_0->u.KExpUnary;
      if (vcase_1->t0.tag == 6) {
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_70 = {0};
         _fx_N14C_form__cexp_t ce1_5 = 0;
         _fx_LN15C_form__cstmt_t ccode_10 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_71 = {0};
         _fx_N14C_form__cexp_t r_exp_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_11 = 0;
         FX_CALL(
            atom2cexp_0.fp(&vcase_1->t1, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
               km_idx_0, &v_70, atom2cexp_0.fcv), _fx_catch_24);
         FX_COPY_PTR(v_70.t0, &ce1_5);
         FX_COPY_PTR(v_70.t1, &ccode_10);
         fx_str_t slit_15 = FX_MAKE_STR("r");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_15, ctyp_0, 0, &kloc_0, block_stack_ref_0, km_idx_0, &v_71, 0), _fx_catch_24);
         FX_COPY_PTR(v_71.t0, &r_exp_0);
         FX_CALL(
            _fx_M10C_gen_codeFM15make_mkref_callLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               ce1_5, r_exp_0, ccode_10, &kloc_0, block_stack_ref_0, &ccode_11, 0), _fx_catch_24);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, r_exp_0, ccode_11, &v_1);

      _fx_catch_24: ;
         if (ccode_11) {
            _fx_free_LN15C_form__cstmt_t(&ccode_11);
         }
         if (r_exp_0) {
            _fx_free_N14C_form__cexp_t(&r_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_71);
         if (ccode_10) {
            _fx_free_LN15C_form__cstmt_t(&ccode_10);
         }
         if (ce1_5) {
            _fx_free_N14C_form__cexp_t(&ce1_5);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_70);
         goto _fx_endmatch_49;
      }
   }
   if (tag_0 == 7) {
      _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_2 = &kexp_0->u.KExpUnary;
      if (vcase_2->t0.tag == 7) {
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_72 = {0};
         _fx_N14C_form__cexp_t ce_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_12 = 0;
         _fx_N14C_form__cexp_t v_73 = 0;
         _fx_N14K_form__atom_t* a1_1 = &vcase_2->t1;
         _fx_R9Ast__id_t a_id_0;
         if (a1_1->tag == 1) {
            a_id_0 = a1_1->u.AtomId;
         }
         else {
            fx_exn_t v_74 = {0};
            fx_str_t slit_16 = FX_MAKE_STR("cgen: deref operand is not an identifier");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_16, &v_74, 0), _fx_catch_25);
            FX_THROW(&v_74, false, _fx_catch_25);

         _fx_catch_25: ;
            fx_free_exn(&v_74);
         }
         FX_CHECK_EXN(_fx_catch_26);
         FX_CALL(
            _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
               &a_id_0, false, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
               &v_72, 0), _fx_catch_26);
         FX_COPY_PTR(v_72.t0, &ce_0);
         FX_COPY_PTR(v_72.t1, &ccode_12);
         _fx_R9Ast__id_t n_id_0;
         fx_str_t slit_17 = FX_MAKE_STR("data");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_17, &n_id_0, 0), _fx_catch_26);
         FX_CALL(
            _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(ce_0, &n_id_0, ctyp_0,
               &v_73, 0), _fx_catch_26);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_73, ccode_12, &v_1);

      _fx_catch_26: ;
         if (v_73) {
            _fx_free_N14C_form__cexp_t(&v_73);
         }
         if (ccode_12) {
            _fx_free_LN15C_form__cstmt_t(&ccode_12);
         }
         if (ce_0) {
            _fx_free_N14C_form__cexp_t(&ce_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_72);
         goto _fx_endmatch_49;
      }
   }
   if (tag_0 == 7) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_75 = {0};
      _fx_N14C_form__cexp_t ce1_6 = 0;
      _fx_LN15C_form__cstmt_t ccode_13 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_76 = {0};
      _fx_N14C_form__cexp_t v_77 = 0;
      _fx_T3N12Ast__unary_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_3 = &kexp_0->u.KExpUnary;
      _fx_N12Ast__unary_t* uop_0 = &vcase_3->t0;
      FX_CALL(
         atom2cexp_0.fp(&vcase_3->t1, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
            km_idx_0, &v_75, atom2cexp_0.fcv), _fx_catch_28);
      FX_COPY_PTR(v_75.t0, &ce1_6);
      FX_COPY_PTR(v_75.t1, &ccode_13);
      int tag_6 = uop_0->tag;
      _fx_N16C_form__cunary_t c_uop_0;
      if (tag_6 == 1) {
         c_uop_0 = _fx_g19C_gen_code__COpPlus; goto _fx_endmatch_8;
      }
      if (tag_6 == 2) {
         c_uop_0 = _fx_g21C_gen_code__COpNegate; goto _fx_endmatch_8;
      }
      if (tag_6 == 4) {
         c_uop_0 = _fx_g25C_gen_code__COpBitwiseNot; goto _fx_endmatch_8;
      }
      if (tag_6 == 5) {
         c_uop_0 = _fx_g23C_gen_code__COpLogicNot; goto _fx_endmatch_8;
      }
      bool res_7;
      if (tag_6 == 7) {
         res_7 = true;
      }
      else if (tag_6 == 6) {
         res_7 = true;
      }
      else if (tag_6 == 8) {
         res_7 = true;
      }
      else if (tag_6 == 3) {
         res_7 = true;
      }
      else if (tag_6 == 9) {
         res_7 = true;
      }
      else {
         res_7 = false;
      }
      FX_CHECK_EXN(_fx_catch_28);
      if (res_7) {
         fx_str_t v_78 = {0};
         fx_str_t v_79 = {0};
         fx_exn_t v_80 = {0};
         FX_CALL(_fx_M3AstFM6stringS1N12Ast__unary_t(uop_0, &v_78, 0), _fx_catch_27);
         fx_str_t slit_18 = FX_MAKE_STR("cgen: unsupported unary op \'");
         fx_str_t slit_19 = FX_MAKE_STR("\'");
         {
            const fx_str_t strs_1[] = { slit_18, v_78, slit_19 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_1, 3, &v_79), _fx_catch_27);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_79, &v_80, 0), _fx_catch_27);
         FX_THROW(&v_80, false, _fx_catch_27);

      _fx_catch_27: ;
         fx_free_exn(&v_80);
         FX_FREE_STR(&v_79);
         FX_FREE_STR(&v_78);
         goto _fx_endmatch_8;
      }
      FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_28);

   _fx_endmatch_8: ;
      FX_CHECK_EXN(_fx_catch_28);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_76);
      FX_CALL(
         _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &c_uop_0, ce1_6, &v_76, &v_77), _fx_catch_28);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_77, ccode_13, &v_1);

   _fx_catch_28: ;
      if (v_77) {
         _fx_free_N14C_form__cexp_t(&v_77);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_76);
      if (ccode_13) {
         _fx_free_LN15C_form__cstmt_t(&ccode_13);
      }
      if (ce1_6) {
         _fx_free_N14C_form__cexp_t(&ce1_6);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_75);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 8) {
      _fx_T3N13Ast__intrin_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_4 = &kexp_0->u.KExpIntrin;
      _fx_LN14K_form__atom_t args_0 = vcase_4->t1;
      _fx_N13Ast__intrin_t* intr_0 = &vcase_4->t0;
      if (intr_0->tag == 2) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_81 = {0};
               _fx_N14C_form__cexp_t cv_1 = 0;
               _fx_LN15C_form__cstmt_t ccode_14 = 0;
               _fx_N14K_form__ktyp_t ktyp_1 = 0;
               _fx_N14C_form__cexp_t extract_ctag_0 = 0;
               _fx_LN14C_form__cexp_t v_82 = 0;
               _fx_N14C_form__cexp_t extract_ctag_1 = 0;
               _fx_N14K_form__atom_t* v_83 = &args_0->hd;
               FX_CALL(
                  atom2cexp_0.fp(v_83, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                     km_idx_0, &v_81, atom2cexp_0.fcv), _fx_catch_32);
               FX_COPY_PTR(v_81.t0, &cv_1);
               FX_COPY_PTR(v_81.t1, &ccode_14);
               FX_CALL(_fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(v_83, &kloc_0, &ktyp_1, 0),
                  _fx_catch_32);
               _fx_R17K_form__ktprops_t v_84;
               FX_CALL(
                  _fx_M10K_annotateFM11get_ktpropsR17K_form__ktprops_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_1, &kloc_0, &v_84,
                     0), _fx_catch_32);
               bool ktp_ptr_0 = v_84.ktp_ptr;
               if (ktp_ptr_0) {
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(cv_1, 0, true, &v_82), _fx_catch_32);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g30C_form__std_FX_REC_VARIANT_TAG, v_82, _fx_g20C_gen_code__CTypCInt, &kloc_0, &extract_ctag_0, 0),
                     _fx_catch_32);
               }
               else {
                  _fx_R9Ast__id_t v_85;
                  fx_str_t slit_20 = FX_MAKE_STR("tag");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_20, &v_85, 0), _fx_catch_32);
                  FX_CALL(
                     _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cv_1, &v_85,
                        _fx_g20C_gen_code__CTypCInt, &extract_ctag_0, 0), _fx_catch_32);
               }
               if (FX_REC_VARIANT_TAG(ktyp_1) == 16) {
                  _fx_N15K_form__kinfo_t v_86 = {0};
                  _fx_R9Ast__id_t* tn_0 = &ktyp_1->u.KTypName;
                  FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(tn_0, &kloc_0, &v_86, 0),
                     _fx_catch_31);
                  if (v_86.tag == 5) {
                     _fx_R21K_form__kdefvariant_t v_87 = {0};
                     _fx_N14C_form__cexp_t v_88 = 0;
                     _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_89 = {0};
                     _fx_N14C_form__cexp_t v_90 = 0;
                     _fx_N14K_form__klit_t v_91 = {0};
                     _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_92 = {0};
                     _fx_N14C_form__cexp_t v_93 = 0;
                     _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_94 = {0};
                     fx_str_t v_95 = {0};
                     fx_str_t v_96 = {0};
                     fx_str_t v_97 = {0};
                     fx_str_t v_98 = {0};
                     fx_str_t v_99 = {0};
                     fx_exn_t v_100 = {0};
                     _fx_copy_R21K_form__kdefvariant_t(&v_86.u.KVariant->data, &v_87);
                     _fx_R16Ast__var_flags_t* kvar_flags_0 = &v_87.kvar_flags;
                     bool have_tag_0 = kvar_flags_0->var_flag_have_tag;
                     bool is_recursive_0 = kvar_flags_0->var_flag_recursive;
                     int_ ncases_0;
                     FX_CALL(_fx_M10C_gen_codeFM8length1_i1LT2R9Ast__id_tN14K_form__ktyp_t(v_87.kvar_cases, &ncases_0, 0),
                        _fx_catch_29);
                     if (have_tag_0) {
                        FX_COPY_PTR(extract_ctag_0, &extract_ctag_1);
                     }
                     else {
                        bool t_4;
                        if (ncases_0 == 1) {
                           t_4 = !is_recursive_0;
                        }
                        else {
                           t_4 = false;
                        }
                        if (t_4) {
                           FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(1, &kloc_0, &extract_ctag_1, 0),
                              _fx_catch_29);
                        }
                        else {
                           bool t_5;
                           if (ncases_0 <= 2) {
                              t_5 = is_recursive_0;
                           }
                           else {
                              t_5 = false;
                           }
                           if (t_5) {
                              _fx_N17C_form__cbinary_t v_101;
                              _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpNE, &v_101);
                              FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_88, 0),
                                 _fx_catch_29);
                              _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypCInt, &kloc_0, &v_89);
                              FX_CALL(
                                 _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                                    &v_101, cv_1, v_88, &v_89, &v_90), _fx_catch_29);
                              _fx_M6K_formFM7KLitIntN14K_form__klit_t1l(1LL, &v_91);
                              _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypCInt, &kloc_0, &v_92);
                              FX_CALL(
                                 _fx_M6C_formFM7CExpLitN14C_form__cexp_t2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(
                                    &v_91, &v_92, &v_93), _fx_catch_29);
                              _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypCInt, &kloc_0, &v_94);
                              FX_CALL(
                                 _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                                    &_fx_g18C_gen_code__COpAdd, v_90, v_93, &v_94, &extract_ctag_1), _fx_catch_29);
                           }
                           else {
                              FX_CALL(_fx_M3AstFM2ppS1RM4id_t(tn_0, &v_95, 0), _fx_catch_29);
                              FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_95, &v_96, 0), _fx_catch_29);
                              FX_CALL(_fx_F6stringS1i(ncases_0, &v_97, 0), _fx_catch_29);
                              FX_CALL(_fx_F6stringS1B(is_recursive_0, &v_98, 0), _fx_catch_29);
                              fx_str_t slit_21 = FX_MAKE_STR("cgen: variant \'");
                              fx_str_t slit_22 = FX_MAKE_STR("\' with no tag has ");
                              fx_str_t slit_23 = FX_MAKE_STR(" cases, is_recursive=");
                              {
                                 const fx_str_t strs_2[] = { slit_21, v_96, slit_22, v_97, slit_23, v_98 };
                                 FX_CALL(fx_strjoin(0, 0, 0, strs_2, 6, &v_99), _fx_catch_29);
                              }
                              FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_99, &v_100, 0), _fx_catch_29);
                              FX_THROW(&v_100, false, _fx_catch_29);
                           }
                        }
                     }

                  _fx_catch_29: ;
                     fx_free_exn(&v_100);
                     FX_FREE_STR(&v_99);
                     FX_FREE_STR(&v_98);
                     FX_FREE_STR(&v_97);
                     FX_FREE_STR(&v_96);
                     FX_FREE_STR(&v_95);
                     _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_94);
                     if (v_93) {
                        _fx_free_N14C_form__cexp_t(&v_93);
                     }
                     _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_92);
                     _fx_free_N14K_form__klit_t(&v_91);
                     if (v_90) {
                        _fx_free_N14C_form__cexp_t(&v_90);
                     }
                     _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_89);
                     if (v_88) {
                        _fx_free_N14C_form__cexp_t(&v_88);
                     }
                     _fx_free_R21K_form__kdefvariant_t(&v_87);
                  }
                  else {
                     fx_str_t v_102 = {0};
                     fx_str_t v_103 = {0};
                     fx_str_t v_104 = {0};
                     fx_exn_t v_105 = {0};
                     FX_CALL(_fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(tn_0, &kloc_0, &v_102, 0), _fx_catch_30);
                     FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_102, &v_103, 0), _fx_catch_30);
                     fx_str_t slit_24 = FX_MAKE_STR("cgen: unexpected type \'");
                     fx_str_t slit_25 = FX_MAKE_STR("\'; should be variant of exception");
                     {
                        const fx_str_t strs_3[] = { slit_24, v_103, slit_25 };
                        FX_CALL(fx_strjoin(0, 0, 0, strs_3, 3, &v_104), _fx_catch_30);
                     }
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_104, &v_105, 0), _fx_catch_30);
                     FX_THROW(&v_105, false, _fx_catch_30);

                  _fx_catch_30: ;
                     fx_free_exn(&v_105);
                     FX_FREE_STR(&v_104);
                     FX_FREE_STR(&v_103);
                     FX_FREE_STR(&v_102);
                  }
                  FX_CHECK_EXN(_fx_catch_31);

               _fx_catch_31: ;
                  _fx_free_N15K_form__kinfo_t(&v_86);
               }
               else {
                  FX_COPY_PTR(extract_ctag_0, &extract_ctag_1);
               }
               FX_CHECK_EXN(_fx_catch_32);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, extract_ctag_1, ccode_14, &v_1);

            _fx_catch_32: ;
               if (extract_ctag_1) {
                  _fx_free_N14C_form__cexp_t(&extract_ctag_1);
               }
               if (v_82) {
                  _fx_free_LN14C_form__cexp_t(&v_82);
               }
               if (extract_ctag_0) {
                  _fx_free_N14C_form__cexp_t(&extract_ctag_0);
               }
               if (ktyp_1) {
                  _fx_free_N14K_form__ktyp_t(&ktyp_1);
               }
               if (ccode_14) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_14);
               }
               if (cv_1) {
                  _fx_free_N14C_form__cexp_t(&cv_1);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_81);
               goto _fx_endmatch_16;
            }
         }
      }
      if (intr_0->tag == 3) {
         if (args_0 != 0) {
            _fx_LN14K_form__atom_t v_106 = args_0->tl;
            if (v_106 != 0) {
               if (v_106->tl == 0) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_107 = {0};
                  _fx_N14C_form__cexp_t cv_2 = 0;
                  _fx_LN15C_form__cstmt_t ccode_15 = 0;
                  _fx_N14K_form__ktyp_t vktyp_0 = 0;
                  _fx_N14K_form__atom_t* vn_val_0 = &v_106->hd;
                  _fx_N14K_form__atom_t* v_108 = &args_0->hd;
                  FX_CALL(
                     atom2cexp_0.fp(v_108, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                        km_idx_0, &v_107, atom2cexp_0.fcv), _fx_catch_42);
                  FX_COPY_PTR(v_107.t0, &cv_2);
                  FX_COPY_PTR(v_107.t1, &ccode_15);
                  FX_CALL(
                     _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(v_108, &kloc_0, &vktyp_0, 0),
                     _fx_catch_42);
                  _fx_R17K_form__ktprops_t v_109;
                  FX_CALL(
                     _fx_M10K_annotateFM11get_ktpropsR17K_form__ktprops_t2N14K_form__ktyp_tR10Ast__loc_t(vktyp_0, &kloc_0,
                        &v_109, 0), _fx_catch_42);
                  bool ktp_ptr_1 = v_109.ktp_ptr;
                  if (FX_REC_VARIANT_TAG(vktyp_0) == 21) {
                     if (vn_val_0->tag == 1) {
                        _fx_N15C_form__cinfo_t v_110 = {0};
                        _fx_R9Ast__id_t* vn_0 = &vn_val_0->u.AtomId;
                        FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(vn_0, &kloc_0, &v_110, 0),
                           _fx_catch_35);
                        if (v_110.tag == 5) {
                           _fx_R17C_form__cdefexn_t v_111 = {0};
                           _fx_N14C_form__cexp_t exn_data_0 = 0;
                           _fx_N14C_form__ctyp_t v_112 = 0;
                           _fx_N14C_form__cexp_t v_113 = 0;
                           _fx_LN14C_form__cexp_t v_114 = 0;
                           _fx_N14C_form__cexp_t exn_data_1 = 0;
                           _fx_copy_R17C_form__cdefexn_t(&v_110.u.CExn->data, &v_111);
                           _fx_R9Ast__id_t v_115;
                           fx_str_t slit_26 = FX_MAKE_STR("data");
                           FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_26, &v_115, 0), _fx_catch_33);
                           FX_CALL(
                              _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cv_2,
                                 &v_115, _fx_g19C_gen_code__CTypAny, &exn_data_0, 0), _fx_catch_33);
                           _fx_R9Ast__id_t v_116;
                           fx_str_t slit_27 = FX_MAKE_STR("FX_EXN_DATA");
                           FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_27, &v_116, 0), _fx_catch_33);
                           FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&v_111.cexn_data, &v_112),
                              _fx_catch_33);
                           FX_CALL(
                              _fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(v_112, &kloc_0, &v_113),
                              _fx_catch_33);
                           FX_CALL(_fx_cons_LN14C_form__cexp_t(exn_data_0, 0, true, &v_114), _fx_catch_33);
                           FX_CALL(_fx_cons_LN14C_form__cexp_t(v_113, v_114, false, &v_114), _fx_catch_33);
                           FX_CALL(
                              _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                                 &v_116, v_114, ctyp_0, &kloc_0, &exn_data_1, 0), _fx_catch_33);
                           _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, exn_data_1, ccode_15, &v_1);

                        _fx_catch_33: ;
                           if (exn_data_1) {
                              _fx_free_N14C_form__cexp_t(&exn_data_1);
                           }
                           if (v_114) {
                              _fx_free_LN14C_form__cexp_t(&v_114);
                           }
                           if (v_113) {
                              _fx_free_N14C_form__cexp_t(&v_113);
                           }
                           if (v_112) {
                              _fx_free_N14C_form__ctyp_t(&v_112);
                           }
                           if (exn_data_0) {
                              _fx_free_N14C_form__cexp_t(&exn_data_0);
                           }
                           _fx_free_R17C_form__cdefexn_t(&v_111);
                        }
                        else {
                           fx_str_t v_117 = {0};
                           fx_str_t v_118 = {0};
                           fx_str_t v_119 = {0};
                           fx_exn_t v_120 = {0};
                           FX_CALL(_fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(vn_0, &kloc_0, &v_117, 0), _fx_catch_34);
                           FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_117, &v_118, 0), _fx_catch_34);
                           fx_str_t slit_28 = FX_MAKE_STR("cgen: information about exception \'");
                           fx_str_t slit_29 = FX_MAKE_STR("\' is not found");
                           {
                              const fx_str_t strs_4[] = { slit_28, v_118, slit_29 };
                              FX_CALL(fx_strjoin(0, 0, 0, strs_4, 3, &v_119), _fx_catch_34);
                           }
                           FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_119, &v_120, 0), _fx_catch_34);
                           FX_THROW(&v_120, false, _fx_catch_34);

                        _fx_catch_34: ;
                           fx_free_exn(&v_120);
                           FX_FREE_STR(&v_119);
                           FX_FREE_STR(&v_118);
                           FX_FREE_STR(&v_117);
                        }
                        FX_CHECK_EXN(_fx_catch_35);

                     _fx_catch_35: ;
                        _fx_free_N15C_form__cinfo_t(&v_110);
                        goto _fx_endmatch_9;
                     }
                  }
                  if (vn_val_0->tag == 2) {
                     _fx_N14K_form__klit_t* v_121 = &vn_val_0->u.AtomLit;
                     if (v_121->tag == 1) {
                        _fx_N14K_form__ktyp_t v_122 = 0;
                        _fx_N14C_form__cexp_t cvu_0 = 0;
                        _fx_N14C_form__cexp_t celem_0 = 0;
                        FX_CALL(
                           _fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(vktyp_0, &kloc_0, &v_122,
                              0), _fx_catch_40);
                        _fx_R9Ast__id_t case_id_0;
                        if (FX_REC_VARIANT_TAG(v_122) == 16) {
                           _fx_N15K_form__kinfo_t v_123 = {0};
                           _fx_R9Ast__id_t* n_0 = &v_122->u.KTypName;
                           FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(n_0, &kloc_0, &v_123, 0),
                              _fx_catch_38);
                           if (v_123.tag == 5) {
                              _fx_R21K_form__kdefvariant_t v_124 = {0};
                              _fx_T2R9Ast__id_tN14K_form__ktyp_t v_125 = {0};
                              _fx_copy_R21K_form__kdefvariant_t(&v_123.u.KVariant->data, &v_124);
                              int_ res_8;
                              FX_CALL(_fx_M10C_gen_codeFM3inti1l(v_121->u.KLitInt, &res_8, 0), _fx_catch_36);
                              FX_CALL(
                                 _fx_M10C_gen_codeFM3nthT2R9Ast__id_tN14K_form__ktyp_t2LT2R9Ast__id_tN14K_form__ktyp_ti(
                                    v_124.kvar_cases, res_8 - 1, &v_125, 0), _fx_catch_36);
                              _fx_R9Ast__id_t v_126 = v_125.t0;
                              FX_CALL(_fx_M3AstFM11get_orig_idRM4id_t1RM4id_t(&v_126, &case_id_0, 0), _fx_catch_36);

                           _fx_catch_36: ;
                              _fx_free_T2R9Ast__id_tN14K_form__ktyp_t(&v_125);
                              _fx_free_R21K_form__kdefvariant_t(&v_124);
                           }
                           else {
                              fx_str_t v_127 = {0};
                              fx_str_t v_128 = {0};
                              fx_str_t v_129 = {0};
                              fx_exn_t v_130 = {0};
                              FX_CALL(_fx_M3AstFM2ppS1RM4id_t(n_0, &v_127, 0), _fx_catch_37);
                              FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_127, &v_128, 0), _fx_catch_37);
                              fx_str_t slit_30 = FX_MAKE_STR("cgen: invalid type \'");
                              fx_str_t slit_31 = FX_MAKE_STR("\'; variant is expected");
                              {
                                 const fx_str_t strs_5[] = { slit_30, v_128, slit_31 };
                                 FX_CALL(fx_strjoin(0, 0, 0, strs_5, 3, &v_129), _fx_catch_37);
                              }
                              FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_129, &v_130, 0), _fx_catch_37);
                              FX_THROW(&v_130, false, _fx_catch_37);

                           _fx_catch_37: ;
                              fx_free_exn(&v_130);
                              FX_FREE_STR(&v_129);
                              FX_FREE_STR(&v_128);
                              FX_FREE_STR(&v_127);
                           }
                           FX_CHECK_EXN(_fx_catch_38);

                        _fx_catch_38: ;
                           _fx_free_N15K_form__kinfo_t(&v_123);
                        }
                        else {
                           fx_str_t v_131 = {0};
                           fx_str_t v_132 = {0};
                           fx_exn_t v_133 = {0};
                           FX_CALL(_fx_M6K_formFM6stringS1N14K_form__ktyp_t(vktyp_0, &v_131, 0), _fx_catch_39);
                           fx_str_t slit_32 = FX_MAKE_STR("cgen: invalid type \'");
                           fx_str_t slit_33 = FX_MAKE_STR("\'; variant is expected");
                           {
                              const fx_str_t strs_6[] = { slit_32, v_131, slit_33 };
                              FX_CALL(fx_strjoin(0, 0, 0, strs_6, 3, &v_132), _fx_catch_39);
                           }
                           FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_132, &v_133, 0), _fx_catch_39);
                           FX_THROW(&v_133, false, _fx_catch_39);

                        _fx_catch_39: ;
                           fx_free_exn(&v_133);
                           FX_FREE_STR(&v_132);
                           FX_FREE_STR(&v_131);
                        }
                        FX_CHECK_EXN(_fx_catch_40);
                        if (ktp_ptr_1) {
                           _fx_R9Ast__id_t v_134;
                           fx_str_t slit_34 = FX_MAKE_STR("u");
                           FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_34, &v_134, 0), _fx_catch_40);
                           FX_CALL(
                              _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cv_2,
                                 &v_134, _fx_g19C_gen_code__CTypAny, &cvu_0, 0), _fx_catch_40);
                        }
                        else {
                           _fx_R9Ast__id_t v_135;
                           fx_str_t slit_35 = FX_MAKE_STR("u");
                           FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_35, &v_135, 0), _fx_catch_40);
                           FX_CALL(
                              _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cv_2,
                                 &v_135, _fx_g19C_gen_code__CTypAny, &cvu_0, 0), _fx_catch_40);
                        }
                        FX_CALL(
                           _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cvu_0,
                              &case_id_0, ctyp_0, &celem_0, 0), _fx_catch_40);
                        _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, celem_0, ccode_15, &v_1);

                     _fx_catch_40: ;
                        if (celem_0) {
                           _fx_free_N14C_form__cexp_t(&celem_0);
                        }
                        if (cvu_0) {
                           _fx_free_N14C_form__cexp_t(&cvu_0);
                        }
                        if (v_122) {
                           _fx_free_N14K_form__ktyp_t(&v_122);
                        }
                        goto _fx_endmatch_9;
                     }
                  }
                  fx_exn_t v_136 = {0};
                  fx_str_t slit_36 = FX_MAKE_STR("cgen: invalid IntrinVariantCase 2nd parameter");
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_36, &v_136, 0), _fx_catch_41);
                  FX_THROW(&v_136, false, _fx_catch_41);

               _fx_catch_41: ;
                  fx_free_exn(&v_136);

               _fx_endmatch_9: ;
                  FX_CHECK_EXN(_fx_catch_42);

               _fx_catch_42: ;
                  if (vktyp_0) {
                     _fx_free_N14K_form__ktyp_t(&vktyp_0);
                  }
                  if (ccode_15) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_15);
                  }
                  if (cv_2) {
                     _fx_free_N14C_form__cexp_t(&cv_2);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_107);
                  goto _fx_endmatch_16;
               }
            }
         }
      }
      if (intr_0->tag == 6) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_137 = {0};
               _fx_N14C_form__cexp_t cl_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_16 = 0;
               _fx_N14C_form__cexp_t v_138 = 0;
               FX_CALL(
                  atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                     i2e_ref_0, km_idx_0, &v_137, atom2cexp_0.fcv), _fx_catch_43);
               FX_COPY_PTR(v_137.t0, &cl_0);
               FX_COPY_PTR(v_137.t1, &ccode_16);
               _fx_R9Ast__id_t v_139;
               fx_str_t slit_37 = FX_MAKE_STR("hd");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_37, &v_139, 0), _fx_catch_43);
               FX_CALL(
                  _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cl_0, &v_139,
                     ctyp_0, &v_138, 0), _fx_catch_43);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_138, ccode_16, &v_1);

            _fx_catch_43: ;
               if (v_138) {
                  _fx_free_N14C_form__cexp_t(&v_138);
               }
               if (ccode_16) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_16);
               }
               if (cl_0) {
                  _fx_free_N14C_form__cexp_t(&cl_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_137);
               goto _fx_endmatch_16;
            }
         }
      }
      if (intr_0->tag == 7) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_140 = {0};
               _fx_N14C_form__cexp_t cl_1 = 0;
               _fx_LN15C_form__cstmt_t ccode_17 = 0;
               _fx_N14C_form__cexp_t v_141 = 0;
               FX_CALL(
                  atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                     i2e_ref_0, km_idx_0, &v_140, atom2cexp_0.fcv), _fx_catch_44);
               FX_COPY_PTR(v_140.t0, &cl_1);
               FX_COPY_PTR(v_140.t1, &ccode_17);
               _fx_R9Ast__id_t v_142;
               fx_str_t slit_38 = FX_MAKE_STR("tl");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_38, &v_142, 0), _fx_catch_44);
               FX_CALL(
                  _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(cl_1, &v_142,
                     ctyp_0, &v_141, 0), _fx_catch_44);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_141, ccode_17, &v_1);

            _fx_catch_44: ;
               if (v_141) {
                  _fx_free_N14C_form__cexp_t(&v_141);
               }
               if (ccode_17) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_17);
               }
               if (cl_1) {
                  _fx_free_N14C_form__cexp_t(&cl_1);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_140);
               goto _fx_endmatch_16;
            }
         }
      }
      if (intr_0->tag == 4) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_Nt6option1rR23C_form__cdefinterface_t v_143 = {0};
               _fx_rR23C_form__cdefinterface_t dst_iface_0 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_144 = {0};
               _fx_N14C_form__cexp_t src_exp_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_18 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_145 = {0};
               _fx_N14C_form__cexp_t dst_exp_1 = 0;
               _fx_LN15C_form__cstmt_t ccode_19 = 0;
               _fx_N14C_form__ctyp_t src_typ_0 = 0;
               _fx_N14C_form__cexp_t get_iface_exp_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_20 = 0;
               FX_CALL(
                  _fx_M6C_formFM18get_cinterface_optNt6option1rRM15cdefinterface_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0,
                     &kloc_0, &v_143, 0), _fx_catch_52);
               if (v_143.tag == 2) {
                  FX_COPY_PTR(v_143.u.Some, &dst_iface_0);
               }
               else {
                  fx_exn_t v_146 = {0};
                  fx_str_t slit_39 =
                     FX_MAKE_STR(
                        "the destination type \'{ctyp2str(ctyp, kloc).0}\' of \'IntrinQueryIface\' intrinsic is not an inteface");
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_39, &v_146, 0), _fx_catch_45);
                  FX_THROW(&v_146, false, _fx_catch_45);

               _fx_catch_45: ;
                  fx_free_exn(&v_146);
               }
               FX_CHECK_EXN(_fx_catch_52);
               FX_CALL(
                  atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                     i2e_ref_0, km_idx_0, &v_144, atom2cexp_0.fcv), _fx_catch_52);
               FX_COPY_PTR(v_144.t0, &src_exp_0);
               FX_COPY_PTR(v_144.t1, &ccode_18);
               fx_str_t slit_40 = FX_MAKE_STR("iface");
               FX_CALL(
                  _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                     dstexp_r_0, &slit_40, ctyp_0, ccode_18, &kloc_0, block_stack_ref_0, km_idx_0, &v_145, 0), _fx_catch_52);
               FX_COPY_PTR(v_145.t0, &dst_exp_1);
               FX_COPY_PTR(v_145.t1, &ccode_19);
               FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(src_exp_0, &src_typ_0, 0), _fx_catch_52);
               if (FX_REC_VARIANT_TAG(src_typ_0) == 21) {
                  _fx_N15C_form__cinfo_t v_147 = {0};
                  FX_CALL(
                     _fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(&src_typ_0->u.CTypName, &kloc_0, &v_147,
                        0), _fx_catch_50);
                  int tag_7 = v_147.tag;
                  if (tag_7 == 6) {
                     _fx_N14C_form__cexp_t v_148 = 0;
                     _fx_N14C_form__cexp_t v_149 = 0;
                     _fx_N14C_form__cexp_t v_150 = 0;
                     _fx_LN14C_form__cexp_t v_151 = 0;
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(src_exp_0, &v_148, 0),
                        _fx_catch_46);
                     _fx_R9Ast__id_t v_152 = dst_iface_0->data.ci_id;
                     FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&v_152, &kloc_0, &v_149, 0),
                        _fx_catch_46);
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_1, &v_150, 0),
                        _fx_catch_46);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_150, 0, true, &v_151), _fx_catch_46);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_149, v_151, false, &v_151), _fx_catch_46);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_148, v_151, false, &v_151), _fx_catch_46);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g26C_form__std_fx_query_iface, v_151, _fx_g20C_gen_code__CTypCInt, &kloc_0, &get_iface_exp_0,
                           0), _fx_catch_46);

                  _fx_catch_46: ;
                     if (v_151) {
                        _fx_free_LN14C_form__cexp_t(&v_151);
                     }
                     if (v_150) {
                        _fx_free_N14C_form__cexp_t(&v_150);
                     }
                     if (v_149) {
                        _fx_free_N14C_form__cexp_t(&v_149);
                     }
                     if (v_148) {
                        _fx_free_N14C_form__cexp_t(&v_148);
                     }
                  }
                  else if (tag_7 == 4) {
                     _fx_R17C_form__cdeftyp_t v_153 = {0};
                     _fx_LR9Ast__id_t ct_ifaces_0 = 0;
                     fx_str_t v_154 = {0};
                     fx_str_t v_155 = {0};
                     _fx_T2SR9Ast__id_t v_156 = {0};
                     fx_str_t v_157 = {0};
                     fx_str_t v_158 = {0};
                     fx_str_t v_159 = {0};
                     fx_exn_t v_160 = {0};
                     _fx_N14C_form__cexp_t v_161 = 0;
                     _fx_N14C_form__cexp_t v_162 = 0;
                     _fx_LN14C_form__cexp_t v_163 = 0;
                     _fx_copy_R17C_form__cdeftyp_t(&v_147.u.CTyp->data, &v_153);
                     int_ idx_0 = -1;
                     int_ i_1 = 0;
                     FX_COPY_PTR(v_153.ct_ifaces, &ct_ifaces_0);
                     _fx_LR9Ast__id_t lst_0 = ct_ifaces_0;
                     for (; lst_0; lst_0 = lst_0->tl, i_1 += 1) {
                        _fx_R9Ast__id_t* iface_0 = &lst_0->hd;
                        _fx_R9Ast__id_t v_164 = dst_iface_0->data.ci_name;
                        bool v_165;
                        FX_CALL(_fx_M3AstFM14same_or_parentB3RM4id_tRM4id_tRM5loc_t(iface_0, &v_164, &kloc_0, &v_165, 0),
                           _fx_catch_47);
                        if (v_165) {
                           idx_0 = i_1; FX_BREAK(_fx_catch_47);
                        }

                     _fx_catch_47: ;
                        FX_CHECK_BREAK();
                        FX_CHECK_EXN(_fx_catch_48);
                     }
                     if (idx_0 < 0) {
                        fx_copy_str(&dst_iface_0->data.ci_cname, &v_154);
                        FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_154, &v_155, 0), _fx_catch_48);
                        FX_CALL(
                           _fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(src_typ_0, &kloc_0, &v_156, 0),
                           _fx_catch_48);
                        fx_copy_str(&v_156.t0, &v_157);
                        FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_157, &v_158, 0), _fx_catch_48);
                        fx_str_t slit_41 = FX_MAKE_STR("the interface \'");
                        fx_str_t slit_42 = FX_MAKE_STR("\' is not implemented by \'");
                        fx_str_t slit_43 = FX_MAKE_STR("\'");
                        {
                           const fx_str_t strs_7[] = { slit_41, v_155, slit_42, v_158, slit_43 };
                           FX_CALL(fx_strjoin(0, 0, 0, strs_7, 5, &v_159), _fx_catch_48);
                        }
                        FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_159, &v_160, 0), _fx_catch_48);
                        FX_THROW(&v_160, false, _fx_catch_48);
                     }
                     FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(idx_0, &kloc_0, &v_161, 0),
                        _fx_catch_48);
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_1, &v_162, 0),
                        _fx_catch_48);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_162, 0, true, &v_163), _fx_catch_48);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_161, v_163, false, &v_163), _fx_catch_48);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(src_exp_0, v_163, false, &v_163), _fx_catch_48);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g25C_form__std_fx_make_iface, v_163, _fx_g20C_gen_code__CTypCInt, &kloc_0, &get_iface_exp_0, 0),
                        _fx_catch_48);

                  _fx_catch_48: ;
                     if (v_163) {
                        _fx_free_LN14C_form__cexp_t(&v_163);
                     }
                     if (v_162) {
                        _fx_free_N14C_form__cexp_t(&v_162);
                     }
                     if (v_161) {
                        _fx_free_N14C_form__cexp_t(&v_161);
                     }
                     fx_free_exn(&v_160);
                     FX_FREE_STR(&v_159);
                     FX_FREE_STR(&v_158);
                     FX_FREE_STR(&v_157);
                     _fx_free_T2SR9Ast__id_t(&v_156);
                     FX_FREE_STR(&v_155);
                     FX_FREE_STR(&v_154);
                     FX_FREE_LIST_SIMPLE(&ct_ifaces_0);
                     _fx_free_R17C_form__cdeftyp_t(&v_153);
                  }
                  else {
                     _fx_T2SR9Ast__id_t v_166 = {0};
                     fx_str_t v_167 = {0};
                     fx_str_t v_168 = {0};
                     fx_str_t v_169 = {0};
                     fx_exn_t v_170 = {0};
                     FX_CALL(
                        _fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(src_typ_0, &kloc_0, &v_166, 0),
                        _fx_catch_49);
                     fx_copy_str(&v_166.t0, &v_167);
                     FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_167, &v_168, 0), _fx_catch_49);
                     fx_str_t slit_44 = FX_MAKE_STR("invalid type \'");
                     fx_str_t slit_45 = FX_MAKE_STR("\' of the first argument of \'IntrinQueryInterface\'");
                     {
                        const fx_str_t strs_8[] = { slit_44, v_168, slit_45 };
                        FX_CALL(fx_strjoin(0, 0, 0, strs_8, 3, &v_169), _fx_catch_49);
                     }
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_169, &v_170, 0), _fx_catch_49);
                     FX_THROW(&v_170, false, _fx_catch_49);

                  _fx_catch_49: ;
                     fx_free_exn(&v_170);
                     FX_FREE_STR(&v_169);
                     FX_FREE_STR(&v_168);
                     FX_FREE_STR(&v_167);
                     _fx_free_T2SR9Ast__id_t(&v_166);
                  }
                  FX_CHECK_EXN(_fx_catch_50);

               _fx_catch_50: ;
                  _fx_free_N15C_form__cinfo_t(&v_147);
               }
               else {
                  _fx_T2SR9Ast__id_t v_171 = {0};
                  fx_str_t v_172 = {0};
                  fx_str_t v_173 = {0};
                  fx_str_t v_174 = {0};
                  fx_exn_t v_175 = {0};
                  FX_CALL(_fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(src_typ_0, &kloc_0, &v_171, 0),
                     _fx_catch_51);
                  fx_copy_str(&v_171.t0, &v_172);
                  FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_172, &v_173, 0), _fx_catch_51);
                  fx_str_t slit_46 = FX_MAKE_STR("invalid type \'");
                  fx_str_t slit_47 = FX_MAKE_STR("\' of the first argument of \'IntrinQueryInterface\'");
                  {
                     const fx_str_t strs_9[] = { slit_46, v_173, slit_47 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_9, 3, &v_174), _fx_catch_51);
                  }
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_174, &v_175, 0), _fx_catch_51);
                  FX_THROW(&v_175, false, _fx_catch_51);

               _fx_catch_51: ;
                  fx_free_exn(&v_175);
                  FX_FREE_STR(&v_174);
                  FX_FREE_STR(&v_173);
                  FX_FREE_STR(&v_172);
                  _fx_free_T2SR9Ast__id_t(&v_171);
               }
               FX_CHECK_EXN(_fx_catch_52);
               FX_CALL(
                  _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     get_iface_exp_0, ccode_19, &kloc_0, block_stack_ref_0, &ccode_20, 0), _fx_catch_52);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_1, ccode_20, &v_1);

            _fx_catch_52: ;
               if (ccode_20) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_20);
               }
               if (get_iface_exp_0) {
                  _fx_free_N14C_form__cexp_t(&get_iface_exp_0);
               }
               if (src_typ_0) {
                  _fx_free_N14C_form__ctyp_t(&src_typ_0);
               }
               if (ccode_19) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_19);
               }
               if (dst_exp_1) {
                  _fx_free_N14C_form__cexp_t(&dst_exp_1);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_145);
               if (ccode_18) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_18);
               }
               if (src_exp_0) {
                  _fx_free_N14C_form__cexp_t(&src_exp_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_144);
               if (dst_iface_0) {
                  _fx_free_rR23C_form__cdefinterface_t(&dst_iface_0);
               }
               _fx_free_Nt6option1rR23C_form__cdefinterface_t(&v_143);
               goto _fx_endmatch_16;
            }
         }
      }
      if (intr_0->tag == 5) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_176 = {0};
               _fx_N14C_form__cexp_t src_exp_1 = 0;
               _fx_LN15C_form__cstmt_t ccode_21 = 0;
               _fx_N14C_form__ctyp_t src_typ_1 = 0;
               _fx_Nt6option1rR23C_form__cdefinterface_t v_177 = {0};
               _fx_rR23C_form__cdefinterface_t src_iface_0 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_178 = {0};
               _fx_N14C_form__cexp_t dst_exp_2 = 0;
               _fx_LN15C_form__cstmt_t ccode_22 = 0;
               _fx_N14C_form__cexp_t get_obj_exp_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_23 = 0;
               FX_CALL(
                  atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                     i2e_ref_0, km_idx_0, &v_176, atom2cexp_0.fcv), _fx_catch_59);
               FX_COPY_PTR(v_176.t0, &src_exp_1);
               FX_COPY_PTR(v_176.t1, &ccode_21);
               FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(src_exp_1, &src_typ_1, 0), _fx_catch_59);
               FX_CALL(
                  _fx_M6C_formFM18get_cinterface_optNt6option1rRM15cdefinterface_t2N14C_form__ctyp_tR10Ast__loc_t(src_typ_1,
                     &kloc_0, &v_177, 0), _fx_catch_59);
               if (v_177.tag == 2) {
                  FX_COPY_PTR(v_177.u.Some, &src_iface_0);
               }
               else {
                  fx_exn_t v_179 = {0};
                  fx_str_t slit_48 =
                     FX_MAKE_STR(
                        "the argument of \'IntrinGetObject\' of type \'{ctyp2str(src_typ, kloc).0}\' is not an inteface");
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_48, &v_179, 0), _fx_catch_53);
                  FX_THROW(&v_179, false, _fx_catch_53);

               _fx_catch_53: ;
                  fx_free_exn(&v_179);
               }
               FX_CHECK_EXN(_fx_catch_59);
               fx_str_t slit_49 = FX_MAKE_STR("iface");
               FX_CALL(
                  _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                     dstexp_r_0, &slit_49, ctyp_0, ccode_21, &kloc_0, block_stack_ref_0, km_idx_0, &v_178, 0), _fx_catch_59);
               FX_COPY_PTR(v_178.t0, &dst_exp_2);
               FX_COPY_PTR(v_178.t1, &ccode_22);
               if (FX_REC_VARIANT_TAG(ctyp_0) == 21) {
                  _fx_N15C_form__cinfo_t v_180 = {0};
                  FX_CALL(
                     _fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(&ctyp_0->u.CTypName, &kloc_0, &v_180, 0),
                     _fx_catch_57);
                  if (v_180.tag == 4) {
                     _fx_R17C_form__cdeftyp_t v_181 = {0};
                     _fx_LR9Ast__id_t ct_ifaces_1 = 0;
                     fx_str_t v_182 = {0};
                     fx_str_t v_183 = {0};
                     _fx_T2SR9Ast__id_t v_184 = {0};
                     fx_str_t v_185 = {0};
                     fx_str_t v_186 = {0};
                     fx_str_t v_187 = {0};
                     fx_exn_t v_188 = {0};
                     _fx_N14C_form__cexp_t v_189 = 0;
                     _fx_N14C_form__cexp_t v_190 = 0;
                     _fx_N14C_form__cexp_t v_191 = 0;
                     _fx_LN14C_form__cexp_t v_192 = 0;
                     _fx_copy_R17C_form__cdeftyp_t(&v_180.u.CTyp->data, &v_181);
                     int_ idx_1 = -1;
                     int_ i_2 = 0;
                     FX_COPY_PTR(v_181.ct_ifaces, &ct_ifaces_1);
                     _fx_LR9Ast__id_t lst_1 = ct_ifaces_1;
                     for (; lst_1; lst_1 = lst_1->tl, i_2 += 1) {
                        _fx_R9Ast__id_t* iface_1 = &lst_1->hd;
                        _fx_R9Ast__id_t v_193 = src_iface_0->data.ci_name;
                        bool v_194;
                        FX_CALL(_fx_M3AstFM14same_or_parentB3RM4id_tRM4id_tRM5loc_t(iface_1, &v_193, &kloc_0, &v_194, 0),
                           _fx_catch_54);
                        if (v_194) {
                           idx_1 = i_2; FX_BREAK(_fx_catch_54);
                        }

                     _fx_catch_54: ;
                        FX_CHECK_BREAK();
                        FX_CHECK_EXN(_fx_catch_55);
                     }
                     if (idx_1 < 0) {
                        fx_copy_str(&src_iface_0->data.ci_cname, &v_182);
                        FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_182, &v_183, 0), _fx_catch_55);
                        FX_CALL(
                           _fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_184, 0),
                           _fx_catch_55);
                        fx_copy_str(&v_184.t0, &v_185);
                        FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_185, &v_186, 0), _fx_catch_55);
                        fx_str_t slit_50 = FX_MAKE_STR("the interface \'");
                        fx_str_t slit_51 = FX_MAKE_STR("\' is not implemented by \'");
                        fx_str_t slit_52 = FX_MAKE_STR("\'");
                        {
                           const fx_str_t strs_10[] = { slit_50, v_183, slit_51, v_186, slit_52 };
                           FX_CALL(fx_strjoin(0, 0, 0, strs_10, 5, &v_187), _fx_catch_55);
                        }
                        FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_187, &v_188, 0), _fx_catch_55);
                        FX_THROW(&v_188, false, _fx_catch_55);
                     }
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(src_exp_1, &v_189, 0),
                        _fx_catch_55);
                     FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(idx_1, &kloc_0, &v_190, 0),
                        _fx_catch_55);
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_2, &v_191, 0),
                        _fx_catch_55);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_191, 0, true, &v_192), _fx_catch_55);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_190, v_192, false, &v_192), _fx_catch_55);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_189, v_192, false, &v_192), _fx_catch_55);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g25C_form__std_fx_get_object, v_192, _fx_g20C_gen_code__CTypCInt, &kloc_0, &get_obj_exp_0, 0),
                        _fx_catch_55);

                  _fx_catch_55: ;
                     if (v_192) {
                        _fx_free_LN14C_form__cexp_t(&v_192);
                     }
                     if (v_191) {
                        _fx_free_N14C_form__cexp_t(&v_191);
                     }
                     if (v_190) {
                        _fx_free_N14C_form__cexp_t(&v_190);
                     }
                     if (v_189) {
                        _fx_free_N14C_form__cexp_t(&v_189);
                     }
                     fx_free_exn(&v_188);
                     FX_FREE_STR(&v_187);
                     FX_FREE_STR(&v_186);
                     FX_FREE_STR(&v_185);
                     _fx_free_T2SR9Ast__id_t(&v_184);
                     FX_FREE_STR(&v_183);
                     FX_FREE_STR(&v_182);
                     FX_FREE_LIST_SIMPLE(&ct_ifaces_1);
                     _fx_free_R17C_form__cdeftyp_t(&v_181);
                  }
                  else {
                     _fx_T2SR9Ast__id_t v_195 = {0};
                     fx_str_t v_196 = {0};
                     fx_str_t v_197 = {0};
                     fx_str_t v_198 = {0};
                     fx_exn_t v_199 = {0};
                     FX_CALL(_fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_195, 0),
                        _fx_catch_56);
                     fx_copy_str(&v_195.t0, &v_196);
                     FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_196, &v_197, 0), _fx_catch_56);
                     fx_str_t slit_53 = FX_MAKE_STR("invalid destination type \'");
                     fx_str_t slit_54 = FX_MAKE_STR("\'. It must be an object that implements some interfaces");
                     {
                        const fx_str_t strs_11[] = { slit_53, v_197, slit_54 };
                        FX_CALL(fx_strjoin(0, 0, 0, strs_11, 3, &v_198), _fx_catch_56);
                     }
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_198, &v_199, 0), _fx_catch_56);
                     FX_THROW(&v_199, false, _fx_catch_56);

                  _fx_catch_56: ;
                     fx_free_exn(&v_199);
                     FX_FREE_STR(&v_198);
                     FX_FREE_STR(&v_197);
                     FX_FREE_STR(&v_196);
                     _fx_free_T2SR9Ast__id_t(&v_195);
                  }
                  FX_CHECK_EXN(_fx_catch_57);

               _fx_catch_57: ;
                  _fx_free_N15C_form__cinfo_t(&v_180);
               }
               else {
                  _fx_T2SR9Ast__id_t v_200 = {0};
                  fx_str_t v_201 = {0};
                  fx_str_t v_202 = {0};
                  fx_str_t v_203 = {0};
                  fx_exn_t v_204 = {0};
                  FX_CALL(_fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_200, 0),
                     _fx_catch_58);
                  fx_copy_str(&v_200.t0, &v_201);
                  FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_201, &v_202, 0), _fx_catch_58);
                  fx_str_t slit_55 = FX_MAKE_STR("invalid destination type \'");
                  fx_str_t slit_56 = FX_MAKE_STR("\'. It must be an object that implements some interfaces");
                  {
                     const fx_str_t strs_12[] = { slit_55, v_202, slit_56 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_12, 3, &v_203), _fx_catch_58);
                  }
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_203, &v_204, 0), _fx_catch_58);
                  FX_THROW(&v_204, false, _fx_catch_58);

               _fx_catch_58: ;
                  fx_free_exn(&v_204);
                  FX_FREE_STR(&v_203);
                  FX_FREE_STR(&v_202);
                  FX_FREE_STR(&v_201);
                  _fx_free_T2SR9Ast__id_t(&v_200);
               }
               FX_CHECK_EXN(_fx_catch_59);
               FX_CALL(
                  _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     get_obj_exp_0, ccode_22, &kloc_0, block_stack_ref_0, &ccode_23, 0), _fx_catch_59);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_2, ccode_23, &v_1);

            _fx_catch_59: ;
               if (ccode_23) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_23);
               }
               if (get_obj_exp_0) {
                  _fx_free_N14C_form__cexp_t(&get_obj_exp_0);
               }
               if (ccode_22) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_22);
               }
               if (dst_exp_2) {
                  _fx_free_N14C_form__cexp_t(&dst_exp_2);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_178);
               if (src_iface_0) {
                  _fx_free_rR23C_form__cdefinterface_t(&src_iface_0);
               }
               _fx_free_Nt6option1rR23C_form__cdefinterface_t(&v_177);
               if (src_typ_1) {
                  _fx_free_N14C_form__ctyp_t(&src_typ_1);
               }
               if (ccode_21) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_21);
               }
               if (src_exp_1) {
                  _fx_free_N14C_form__cexp_t(&src_exp_1);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_176);
               goto _fx_endmatch_16;
            }
         }
      }
      if (args_0 == 0) {
         if (intr_0->tag == 1) {
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_205 = {0};
            _fx_N14C_form__cexp_t dst_exp_3 = 0;
            _fx_LN15C_form__cstmt_t ccode_24 = 0;
            _fx_N14C_form__cexp_t fx_status_exp_0 = 0;
            _fx_N14C_form__cexp_t v_206 = 0;
            _fx_LN14C_form__cexp_t v_207 = 0;
            _fx_N14C_form__cexp_t e_7 = 0;
            _fx_N15C_form__cstmt_t v_208 = 0;
            _fx_LN15C_form__cstmt_t v_209 = 0;
            fx_str_t slit_57 = FX_MAKE_STR("curr_exn");
            FX_CALL(
               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                  dstexp_r_0, &slit_57, _fx_g19C_gen_code__CTypExn, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_205, 0),
               _fx_catch_60);
            FX_COPY_PTR(v_205.t0, &dst_exp_3);
            FX_COPY_PTR(v_205.t1, &ccode_24);
            FX_CALL(
               _fx_M10C_gen_codeFM14make_fx_statusN14C_form__cexp_t2R10Ast__loc_tR9Ast__id_t(&kloc_0, fx_status__0,
                  &fx_status_exp_0, 0), _fx_catch_60);
            _fx_R9Ast__id_t v_210;
            fx_str_t slit_58 = FX_MAKE_STR("fx_exn_get_and_reset");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_58, &v_210, 0), _fx_catch_60);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_3, &v_206, 0), _fx_catch_60);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_206, 0, true, &v_207), _fx_catch_60);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(fx_status_exp_0, v_207, false, &v_207), _fx_catch_60);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_210,
                  v_207, _fx_g20C_gen_code__CTypVoid, &kloc_0, &e_7, 0), _fx_catch_60);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(e_7, &v_208), _fx_catch_60);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_208, ccode_24, true, &v_209), _fx_catch_60);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_3, v_209, &v_1);

         _fx_catch_60: ;
            if (v_209) {
               _fx_free_LN15C_form__cstmt_t(&v_209);
            }
            if (v_208) {
               _fx_free_N15C_form__cstmt_t(&v_208);
            }
            if (e_7) {
               _fx_free_N14C_form__cexp_t(&e_7);
            }
            if (v_207) {
               _fx_free_LN14C_form__cexp_t(&v_207);
            }
            if (v_206) {
               _fx_free_N14C_form__cexp_t(&v_206);
            }
            if (fx_status_exp_0) {
               _fx_free_N14C_form__cexp_t(&fx_status_exp_0);
            }
            if (ccode_24) {
               _fx_free_LN15C_form__cstmt_t(&ccode_24);
            }
            if (dst_exp_3) {
               _fx_free_N14C_form__cexp_t(&dst_exp_3);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_205);
            goto _fx_endmatch_16;
         }
      }
      if (intr_0->tag == 8) {
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___0 = {0};
         _fx_LN14K_form__atom_t args_1 = 0;
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_211 = {0};
         _fx_LN14C_form__cexp_t strs_13 = 0;
         _fx_LN15C_form__cstmt_t ccode_25 = 0;
         _fx_LN19C_form__ctyp_attr_t v_212 = 0;
         _fx_N14C_form__ctyp_t strs_ctyp_0 = 0;
         _fx_LN14C_form__cexp_t v_213 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_214 = {0};
         _fx_N14C_form__cexp_t strs0_0 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_215 = {0};
         _fx_N14C_form__cexp_t dst_exp_4 = 0;
         _fx_LN15C_form__cstmt_t ccode_26 = 0;
         _fx_R16Ast__val_flags_t v_216 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_217 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_218 = {0};
         _fx_N14C_form__cexp_t strs_exp_0 = 0;
         _fx_LN15C_form__cstmt_t sub_ccode_0 = 0;
         _fx_N14C_form__cexp_t v_219 = 0;
         _fx_N14C_form__cexp_t v_220 = 0;
         _fx_N14C_form__cexp_t v_221 = 0;
         _fx_N14C_form__cexp_t v_222 = 0;
         _fx_N14C_form__cexp_t v_223 = 0;
         _fx_LN14C_form__cexp_t v_224 = 0;
         _fx_N14C_form__cexp_t call_exp_0 = 0;
         _fx_LN15C_form__cstmt_t sub_ccode_1 = 0;
         _fx_N15C_form__cstmt_t v_225 = 0;
         _fx_LN15C_form__cstmt_t ccode_27 = 0;
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_0, &__fold_result___0);
         FX_COPY_PTR(args_0, &args_1);
         _fx_LN14K_form__atom_t lst_2 = args_1;
         for (; lst_2; lst_2 = lst_2->tl) {
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_226 = {0};
            _fx_LN14C_form__cexp_t strs_14 = 0;
            _fx_LN15C_form__cstmt_t ccode_28 = 0;
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_227 = {0};
            _fx_N14C_form__cexp_t c_exp_0 = 0;
            _fx_LN15C_form__cstmt_t ccode_29 = 0;
            _fx_N14C_form__ctyp_t v_228 = 0;
            _fx_N14C_form__cexp_t s_exp_0 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_229 = {0};
            _fx_N14K_form__atom_t* a_0 = &lst_2->hd;
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___0, &v_226);
            FX_COPY_PTR(v_226.t0, &strs_14);
            FX_COPY_PTR(v_226.t1, &ccode_28);
            FX_CALL(atom2cexp__0.fp(a_0, true, ccode_28, &kloc_0, &v_227, atom2cexp__0.fcv), _fx_catch_63);
            FX_COPY_PTR(v_227.t0, &c_exp_0);
            FX_COPY_PTR(v_227.t1, &ccode_29);
            FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(c_exp_0, &v_228, 0), _fx_catch_63);
            if (FX_REC_VARIANT_TAG(v_228) == 10) {
               if (a_0->tag == 2) {
                  _fx_N14K_form__klit_t* v_230 = &a_0->u.AtomLit;
                  if (v_230->tag == 6) {
                     fx_str_t v_231 = {0};
                     _fx_N14K_form__klit_t v_232 = {0};
                     _fx_N14C_form__cexp_t v_233 = 0;
                     _fx_LN14C_form__cexp_t v_234 = 0;
                     _fx_R9Ast__id_t v_235;
                     fx_str_t slit_59 = FX_MAKE_STR("FX_MAKE_STR1");
                     FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_59, &v_235, 0), _fx_catch_61);
                     FX_CALL(_fx_F6stringS1C(v_230->u.KLitChar, &v_231, 0), _fx_catch_61);
                     _fx_M6K_formFM10KLitStringN14K_form__klit_t1S(&v_231, &v_232);
                     FX_CALL(
                        _fx_M6C_formFM12make_lit_expN14C_form__cexp_t2N14K_form__klit_tR10Ast__loc_t(&v_232, &kloc_0, &v_233,
                           0), _fx_catch_61);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_233, 0, true, &v_234), _fx_catch_61);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_235, v_234, _fx_g22C_gen_code__CTypString, &kloc_0, &s_exp_0, 0), _fx_catch_61);

                  _fx_catch_61: ;
                     if (v_234) {
                        _fx_free_LN14C_form__cexp_t(&v_234);
                     }
                     if (v_233) {
                        _fx_free_N14C_form__cexp_t(&v_233);
                     }
                     _fx_free_N14K_form__klit_t(&v_232);
                     FX_FREE_STR(&v_231);
                     goto _fx_endmatch_10;
                  }
               }
            }
            if (FX_REC_VARIANT_TAG(v_228) == 10) {
               if (a_0->tag == 1) {
                  _fx_LN14C_form__cexp_t v_236 = 0;
                  _fx_R9Ast__id_t v_237;
                  fx_str_t slit_60 = FX_MAKE_STR("FX_MAKE_VAR_STR1");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_60, &v_237, 0), _fx_catch_62);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(c_exp_0, 0, true, &v_236), _fx_catch_62);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_237, v_236, _fx_g22C_gen_code__CTypString, &kloc_0, &s_exp_0, 0), _fx_catch_62);

               _fx_catch_62: ;
                  if (v_236) {
                     _fx_free_LN14C_form__cexp_t(&v_236);
                  }
                  goto _fx_endmatch_10;
               }
            }
            FX_COPY_PTR(c_exp_0, &s_exp_0);

         _fx_endmatch_10: ;
            FX_CHECK_EXN(_fx_catch_63);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(s_exp_0, strs_14, false, &strs_14), _fx_catch_63);
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(strs_14, ccode_29, &v_229);
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___0);
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_229, &__fold_result___0);

         _fx_catch_63: ;
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_229);
            if (s_exp_0) {
               _fx_free_N14C_form__cexp_t(&s_exp_0);
            }
            if (v_228) {
               _fx_free_N14C_form__ctyp_t(&v_228);
            }
            if (ccode_29) {
               _fx_free_LN15C_form__cstmt_t(&ccode_29);
            }
            if (c_exp_0) {
               _fx_free_N14C_form__cexp_t(&c_exp_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_227);
            if (ccode_28) {
               _fx_free_LN15C_form__cstmt_t(&ccode_28);
            }
            if (strs_14) {
               _fx_free_LN14C_form__cexp_t(&strs_14);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_226);
            FX_CHECK_EXN(_fx_catch_64);
         }
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___0, &v_211);
         FX_COPY_PTR(v_211.t0, &strs_13);
         FX_COPY_PTR(v_211.t1, &ccode_25);
         _fx_R9Ast__id_t strs_id_0;
         fx_str_t slit_61 = FX_MAKE_STR("strs");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_61, &strs_id_0, 0), _fx_catch_64);
         FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_212), _fx_catch_64);
         FX_CALL(
            _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_212,
               _fx_g22C_gen_code__CTypString, &strs_ctyp_0), _fx_catch_64);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(strs_13, &v_213, 0), _fx_catch_64);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(strs_ctyp_0, &kloc_0, &v_214);
         FX_CALL(
            _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(v_213, &v_214,
               &strs0_0), _fx_catch_64);
         fx_str_t slit_62 = FX_MAKE_STR("concat_str");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_62, _fx_g22C_gen_code__CTypString, ccode_25, &kloc_0, block_stack_ref_0, km_idx_0, &v_215, 0),
            _fx_catch_64);
         FX_COPY_PTR(v_215.t0, &dst_exp_4);
         FX_COPY_PTR(v_215.t1, &ccode_26);
         FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_216, 0), _fx_catch_64);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(strs0_0, &v_217);
         fx_str_t slit_63 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &strs_id_0, strs_ctyp_0, &v_216, &slit_63, &v_217, 0, &kloc_0, &v_218, 0), _fx_catch_64);
         FX_COPY_PTR(v_218.t0, &strs_exp_0);
         FX_COPY_PTR(v_218.t1, &sub_ccode_0);
         _fx_R9Ast__id_t v_238;
         fx_str_t slit_64 = FX_MAKE_STR("fx_strjoin");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_64, &v_238, 0), _fx_catch_64);
         FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_219, 0), _fx_catch_64);
         FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_220, 0), _fx_catch_64);
         FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_221, 0), _fx_catch_64);
         int_ v_239;
         FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(strs_13, &v_239, 0), _fx_catch_64);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(v_239, &kloc_0, &v_222, 0), _fx_catch_64);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_4, &v_223, 0), _fx_catch_64);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_223, 0, true, &v_224), _fx_catch_64);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_222, v_224, false, &v_224), _fx_catch_64);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(strs_exp_0, v_224, false, &v_224), _fx_catch_64);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_221, v_224, false, &v_224), _fx_catch_64);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_220, v_224, false, &v_224), _fx_catch_64);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_219, v_224, false, &v_224), _fx_catch_64);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_238, v_224,
               _fx_g19C_gen_code__CTypInt, &kloc_0, &call_exp_0, 0), _fx_catch_64);
         FX_CALL(
            _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               call_exp_0, sub_ccode_0, &kloc_0, block_stack_ref_0, &sub_ccode_1, 0), _fx_catch_64);
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(sub_ccode_1, &kloc_0, &v_225, 0),
            _fx_catch_64);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_225, ccode_26, true, &ccode_27), _fx_catch_64);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_4, ccode_27, &v_1);

      _fx_catch_64: ;
         if (ccode_27) {
            _fx_free_LN15C_form__cstmt_t(&ccode_27);
         }
         if (v_225) {
            _fx_free_N15C_form__cstmt_t(&v_225);
         }
         if (sub_ccode_1) {
            _fx_free_LN15C_form__cstmt_t(&sub_ccode_1);
         }
         if (call_exp_0) {
            _fx_free_N14C_form__cexp_t(&call_exp_0);
         }
         if (v_224) {
            _fx_free_LN14C_form__cexp_t(&v_224);
         }
         if (v_223) {
            _fx_free_N14C_form__cexp_t(&v_223);
         }
         if (v_222) {
            _fx_free_N14C_form__cexp_t(&v_222);
         }
         if (v_221) {
            _fx_free_N14C_form__cexp_t(&v_221);
         }
         if (v_220) {
            _fx_free_N14C_form__cexp_t(&v_220);
         }
         if (v_219) {
            _fx_free_N14C_form__cexp_t(&v_219);
         }
         if (sub_ccode_0) {
            _fx_free_LN15C_form__cstmt_t(&sub_ccode_0);
         }
         if (strs_exp_0) {
            _fx_free_N14C_form__cexp_t(&strs_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_218);
         _fx_free_Nt6option1N14C_form__cexp_t(&v_217);
         _fx_free_R16Ast__val_flags_t(&v_216);
         if (ccode_26) {
            _fx_free_LN15C_form__cstmt_t(&ccode_26);
         }
         if (dst_exp_4) {
            _fx_free_N14C_form__cexp_t(&dst_exp_4);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_215);
         if (strs0_0) {
            _fx_free_N14C_form__cexp_t(&strs0_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_214);
         if (v_213) {
            _fx_free_LN14C_form__cexp_t(&v_213);
         }
         if (strs_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&strs_ctyp_0);
         }
         FX_FREE_LIST_SIMPLE(&v_212);
         if (ccode_25) {
            _fx_free_LN15C_form__cstmt_t(&ccode_25);
         }
         if (strs_13) {
            _fx_free_LN14C_form__cexp_t(&strs_13);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_211);
         if (args_1) {
            _fx_free_LN14K_form__atom_t(&args_1);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___0);
         goto _fx_endmatch_16;
      }
      if (intr_0->tag == 9) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_240 = {0};
               _fx_N14C_form__cexp_t arr_exp_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_30 = 0;
               _fx_N14K_form__ktyp_t v_241 = 0;
               _fx_N14C_form__cexp_t c_e_0 = 0;
               _fx_N14K_form__atom_t* arr_or_str_0 = &args_0->hd;
               FX_CALL(
                  atom2cexp_0.fp(arr_or_str_0, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                     i2e_ref_0, km_idx_0, &v_240, atom2cexp_0.fcv), _fx_catch_69);
               FX_COPY_PTR(v_240.t0, &arr_exp_0);
               FX_COPY_PTR(v_240.t1, &ccode_30);
               FX_CALL(
                  _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(arr_or_str_0, &kloc_0, &v_241,
                     0), _fx_catch_69);
               int tag_8 = FX_REC_VARIANT_TAG(v_241);
               if (tag_8 == 10) {
                  _fx_LN14C_form__cexp_t v_242 = 0;
                  _fx_R9Ast__id_t v_243;
                  fx_str_t slit_65 = FX_MAKE_STR("FX_STR_LENGTH");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_65, &v_243, 0), _fx_catch_65);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_0, 0, true, &v_242), _fx_catch_65);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_243, v_242, _fx_g19C_gen_code__CTypInt, &kloc_0, &c_e_0, 0), _fx_catch_65);

               _fx_catch_65: ;
                  if (v_242) {
                     _fx_free_LN14C_form__cexp_t(&v_242);
                  }
               }
               else if (tag_8 == 17) {
                  _fx_N14C_form__cexp_t v_244 = 0;
                  _fx_LN14C_form__cexp_t v_245 = 0;
                  _fx_R9Ast__id_t v_246;
                  fx_str_t slit_66 = FX_MAKE_STR("FX_ARR_SIZE");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_66, &v_246, 0), _fx_catch_66);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_244, 0), _fx_catch_66);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_244, 0, true, &v_245), _fx_catch_66);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_0, v_245, false, &v_245), _fx_catch_66);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_246, v_245, _fx_g19C_gen_code__CTypInt, &kloc_0, &c_e_0, 0), _fx_catch_66);

               _fx_catch_66: ;
                  if (v_245) {
                     _fx_free_LN14C_form__cexp_t(&v_245);
                  }
                  if (v_244) {
                     _fx_free_N14C_form__cexp_t(&v_244);
                  }
               }
               else if (tag_8 == 18) {
                  _fx_LN14C_form__cexp_t v_247 = 0;
                  _fx_R9Ast__id_t v_248;
                  fx_str_t slit_67 = FX_MAKE_STR("FX_RRB_SIZE");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_67, &v_248, 0), _fx_catch_67);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_0, 0, true, &v_247), _fx_catch_67);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_248, v_247, _fx_g19C_gen_code__CTypInt, &kloc_0, &c_e_0, 0), _fx_catch_67);

               _fx_catch_67: ;
                  if (v_247) {
                     _fx_free_LN14C_form__cexp_t(&v_247);
                  }
               }
               else {
                  fx_str_t v_249 = {0};
                  fx_str_t v_250 = {0};
                  fx_str_t v_251 = {0};
                  fx_str_t v_252 = {0};
                  fx_exn_t v_253 = {0};
                  FX_CALL(_fx_M6K_formFM6stringS1N14K_form__ktyp_t(v_241, &v_249, 0), _fx_catch_68);
                  FX_CALL(_fx_M6K_formFM8atom2strS1N14K_form__atom_t(arr_or_str_0, &v_250, 0), _fx_catch_68);
                  FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_250, &v_251, 0), _fx_catch_68);
                  fx_str_t slit_68 = FX_MAKE_STR("cgen: unsupported container type ");
                  fx_str_t slit_69 = FX_MAKE_STR(" of ");
                  fx_str_t slit_70 = FX_MAKE_STR(" in KExpIntrin(IntrinGetSize...)");
                  {
                     const fx_str_t strs_15[] = { slit_68, v_249, slit_69, v_251, slit_70 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_15, 5, &v_252), _fx_catch_68);
                  }
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_252, &v_253, 0), _fx_catch_68);
                  FX_THROW(&v_253, false, _fx_catch_68);

               _fx_catch_68: ;
                  fx_free_exn(&v_253);
                  FX_FREE_STR(&v_252);
                  FX_FREE_STR(&v_251);
                  FX_FREE_STR(&v_250);
                  FX_FREE_STR(&v_249);
               }
               FX_CHECK_EXN(_fx_catch_69);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, c_e_0, ccode_30, &v_1);

            _fx_catch_69: ;
               if (c_e_0) {
                  _fx_free_N14C_form__cexp_t(&c_e_0);
               }
               if (v_241) {
                  _fx_free_N14K_form__ktyp_t(&v_241);
               }
               if (ccode_30) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_30);
               }
               if (arr_exp_0) {
                  _fx_free_N14C_form__cexp_t(&arr_exp_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_240);
               goto _fx_endmatch_16;
            }
         }
      }
      if (intr_0->tag == 9) {
         if (args_0 != 0) {
            _fx_LN14K_form__atom_t v_254 = args_0->tl;
            if (v_254 != 0) {
               if (v_254->tl == 0) {
                  _fx_N14K_form__atom_t* v_255 = &v_254->hd;
                  if (v_255->tag == 2) {
                     _fx_N14K_form__klit_t* v_256 = &v_255->u.AtomLit;
                     if (v_256->tag == 1) {
                        _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_257 = {0};
                        _fx_N14C_form__cexp_t arr_exp_1 = 0;
                        _fx_LN15C_form__cstmt_t ccode_31 = 0;
                        _fx_N14K_form__ktyp_t v_258 = 0;
                        _fx_N14C_form__cexp_t c_e_1 = 0;
                        int64_t i_3 = v_256->u.KLitInt;
                        _fx_N14K_form__atom_t* arr_or_str_1 = &args_0->hd;
                        FX_CALL(
                           atom2cexp_0.fp(arr_or_str_1, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                              fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_257, atom2cexp_0.fcv), _fx_catch_74);
                        FX_COPY_PTR(v_257.t0, &arr_exp_1);
                        FX_COPY_PTR(v_257.t1, &ccode_31);
                        FX_CALL(
                           _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(arr_or_str_1, &kloc_0,
                              &v_258, 0), _fx_catch_74);
                        if (i_3 == 0LL) {
                           if (FX_REC_VARIANT_TAG(v_258) == 10) {
                              _fx_LN14C_form__cexp_t v_259 = 0;
                              _fx_R9Ast__id_t v_260;
                              fx_str_t slit_71 = FX_MAKE_STR("FX_STR_LENGTH");
                              FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_71, &v_260, 0), _fx_catch_70);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_1, 0, true, &v_259), _fx_catch_70);
                              FX_CALL(
                                 _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                                    &v_260, v_259, _fx_g19C_gen_code__CTypInt, &kloc_0, &c_e_1, 0), _fx_catch_70);

                           _fx_catch_70: ;
                              if (v_259) {
                                 _fx_free_LN14C_form__cexp_t(&v_259);
                              }
                              goto _fx_endmatch_11;
                           }
                        }
                        if (i_3 == 0LL) {
                           if (FX_REC_VARIANT_TAG(v_258) == 18) {
                              _fx_LN14C_form__cexp_t v_261 = 0;
                              _fx_R9Ast__id_t v_262;
                              fx_str_t slit_72 = FX_MAKE_STR("FX_RRB_SIZE");
                              FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_72, &v_262, 0), _fx_catch_71);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_1, 0, true, &v_261), _fx_catch_71);
                              FX_CALL(
                                 _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                                    &v_262, v_261, _fx_g19C_gen_code__CTypInt, &kloc_0, &c_e_1, 0), _fx_catch_71);

                           _fx_catch_71: ;
                              if (v_261) {
                                 _fx_free_LN14C_form__cexp_t(&v_261);
                              }
                              goto _fx_endmatch_11;
                           }
                        }
                        if (FX_REC_VARIANT_TAG(v_258) == 17) {
                           fx_str_t v_263 = {0};
                           fx_str_t v_264 = {0};
                           fx_str_t v_265 = {0};
                           fx_exn_t v_266 = {0};
                           _fx_N14C_form__cexp_t v_267 = 0;
                           _fx_LN14C_form__cexp_t v_268 = 0;
                           int_ ndims_0 = v_258->u.KTypArray.t0;
                           bool t_6;
                           if (0LL <= i_3) {
                              int64_t res_9;
                              FX_CALL(_fx_M10C_gen_codeFM5int64l1i(ndims_0, &res_9, 0), _fx_catch_72);
                              t_6 = i_3 < res_9;
                           }
                           else {
                              t_6 = false;
                           }
                           if (!t_6) {
                              FX_CALL(_fx_F6stringS1l(i_3, &v_263, 0), _fx_catch_72);
                              FX_CALL(_fx_F6stringS1i(ndims_0, &v_264, 0), _fx_catch_72);
                              fx_str_t slit_73 = FX_MAKE_STR("array dimension index ");
                              fx_str_t slit_74 = FX_MAKE_STR("i is beyond dimensionality ");
                              {
                                 const fx_str_t strs_16[] = { slit_73, v_263, slit_74, v_264 };
                                 FX_CALL(fx_strjoin(0, 0, 0, strs_16, 4, &v_265), _fx_catch_72);
                              }
                              FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_265, &v_266, 0), _fx_catch_72);
                              FX_THROW(&v_266, false, _fx_catch_72);
                           }
                           _fx_R9Ast__id_t v_269;
                           fx_str_t slit_75 = FX_MAKE_STR("FX_ARR_SIZE");
                           FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_75, &v_269, 0), _fx_catch_72);
                           FX_CALL(_fx_M6C_formFM13make_int__expN14C_form__cexp_t2lR10Ast__loc_t(i_3, &kloc_0, &v_267, 0),
                              _fx_catch_72);
                           FX_CALL(_fx_cons_LN14C_form__cexp_t(v_267, 0, true, &v_268), _fx_catch_72);
                           FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_1, v_268, false, &v_268), _fx_catch_72);
                           FX_CALL(
                              _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                                 &v_269, v_268, _fx_g19C_gen_code__CTypInt, &kloc_0, &c_e_1, 0), _fx_catch_72);

                        _fx_catch_72: ;
                           if (v_268) {
                              _fx_free_LN14C_form__cexp_t(&v_268);
                           }
                           if (v_267) {
                              _fx_free_N14C_form__cexp_t(&v_267);
                           }
                           fx_free_exn(&v_266);
                           FX_FREE_STR(&v_265);
                           FX_FREE_STR(&v_264);
                           FX_FREE_STR(&v_263);
                           goto _fx_endmatch_11;
                        }
                        fx_exn_t v_270 = {0};
                        fx_str_t slit_76 = FX_MAKE_STR("cgen: unsupported container type in KExpIntrin(IntrinGetSize...)");
                        FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_76, &v_270, 0), _fx_catch_73);
                        FX_THROW(&v_270, false, _fx_catch_73);

                     _fx_catch_73: ;
                        fx_free_exn(&v_270);

                     _fx_endmatch_11: ;
                        FX_CHECK_EXN(_fx_catch_74);
                        _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, c_e_1, ccode_31, &v_1);

                     _fx_catch_74: ;
                        if (c_e_1) {
                           _fx_free_N14C_form__cexp_t(&c_e_1);
                        }
                        if (v_258) {
                           _fx_free_N14K_form__ktyp_t(&v_258);
                        }
                        if (ccode_31) {
                           _fx_free_LN15C_form__cstmt_t(&ccode_31);
                        }
                        if (arr_exp_1) {
                           _fx_free_N14C_form__cexp_t(&arr_exp_1);
                        }
                        _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_257);
                        goto _fx_endmatch_16;
                     }
                  }
               }
            }
         }
      }
      if (intr_0->tag == 10) {
         if (args_0 != 0) {
            _fx_LN14K_form__atom_t v_271 = args_0->tl;
            if (v_271 != 0) {
               if (v_271->tl == 0) {
                  _fx_N14C_form__cexp_t lbl_3 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_272 = {0};
                  _fx_N14C_form__cexp_t arrsz_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_32 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_273 = {0};
                  _fx_N14C_form__cexp_t idx_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_33 = 0;
                  _fx_LN14C_form__cexp_t v_274 = 0;
                  _fx_N14C_form__cexp_t chk_0 = 0;
                  _fx_N15C_form__cstmt_t v_275 = 0;
                  _fx_LN15C_form__cstmt_t v_276 = 0;
                  FX_CALL(
                     _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0,
                        block_stack_ref_0, &lbl_3, 0), _fx_catch_75);
                  FX_CALL(
                     atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_272, atom2cexp_0.fcv), _fx_catch_75);
                  FX_COPY_PTR(v_272.t0, &arrsz_exp_0);
                  FX_COPY_PTR(v_272.t1, &ccode_32);
                  FX_CALL(
                     atom2cexp_0.fp(&v_271->hd, ccode_32, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_273, atom2cexp_0.fcv), _fx_catch_75);
                  FX_COPY_PTR(v_273.t0, &idx_exp_0);
                  FX_COPY_PTR(v_273.t1, &ccode_33);
                  _fx_R9Ast__id_t v_277;
                  fx_str_t slit_77 = FX_MAKE_STR("FX_CHKIDX_SCALAR");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_77, &v_277, 0), _fx_catch_75);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_3, 0, true, &v_274), _fx_catch_75);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(idx_exp_0, v_274, false, &v_274), _fx_catch_75);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arrsz_exp_0, v_274, false, &v_274), _fx_catch_75);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_277, v_274, _fx_g20C_gen_code__CTypVoid, &kloc_0, &chk_0, 0), _fx_catch_75);
                  FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(chk_0, &v_275), _fx_catch_75);
                  FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_275, ccode_33, true, &v_276), _fx_catch_75);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_276, &v_1);

               _fx_catch_75: ;
                  if (v_276) {
                     _fx_free_LN15C_form__cstmt_t(&v_276);
                  }
                  if (v_275) {
                     _fx_free_N15C_form__cstmt_t(&v_275);
                  }
                  if (chk_0) {
                     _fx_free_N14C_form__cexp_t(&chk_0);
                  }
                  if (v_274) {
                     _fx_free_LN14C_form__cexp_t(&v_274);
                  }
                  if (ccode_33) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_33);
                  }
                  if (idx_exp_0) {
                     _fx_free_N14C_form__cexp_t(&idx_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_273);
                  if (ccode_32) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_32);
                  }
                  if (arrsz_exp_0) {
                     _fx_free_N14C_form__cexp_t(&arrsz_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_272);
                  if (lbl_3) {
                     _fx_free_N14C_form__cexp_t(&lbl_3);
                  }
                  goto _fx_endmatch_16;
               }
            }
         }
      }
      if (intr_0->tag == 11) {
         if (args_0 != 0) {
            _fx_LN14K_form__atom_t v_278 = args_0->tl;
            if (v_278 != 0) {
               _fx_LN14K_form__atom_t v_279 = v_278->tl;
               if (v_279 != 0) {
                  _fx_LN14K_form__atom_t v_280 = v_279->tl;
                  if (v_280 != 0) {
                     _fx_LN14K_form__atom_t v_281 = v_280->tl;
                     if (v_281 != 0) {
                        _fx_LN14K_form__atom_t v_282 = v_281->tl;
                        if (v_282 != 0) {
                           if (v_282->tl == 0) {
                              _fx_N14C_form__cexp_t lbl_4 = 0;
                              _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_283 = {0};
                              _fx_N14C_form__cexp_t arrsz_exp_1 = 0;
                              _fx_LN15C_form__cstmt_t ccode_34 = 0;
                              _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_284 = {0};
                              _fx_N14C_form__cexp_t a_exp_0 = 0;
                              _fx_LN15C_form__cstmt_t ccode_35 = 0;
                              _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_285 = {0};
                              _fx_N14C_form__cexp_t b_exp_0 = 0;
                              _fx_LN15C_form__cstmt_t ccode_36 = 0;
                              _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_286 = {0};
                              _fx_N14C_form__cexp_t delta_exp_0 = 0;
                              _fx_LN15C_form__cstmt_t ccode_37 = 0;
                              _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_287 = {0};
                              _fx_N14C_form__cexp_t scale_exp_0 = 0;
                              _fx_LN15C_form__cstmt_t ccode_38 = 0;
                              _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_288 = {0};
                              _fx_N14C_form__cexp_t shift_exp_0 = 0;
                              _fx_LN15C_form__cstmt_t ccode_39 = 0;
                              _fx_LN14C_form__cexp_t v_289 = 0;
                              _fx_N14C_form__cexp_t chk_1 = 0;
                              _fx_N15C_form__cstmt_t v_290 = 0;
                              _fx_LN15C_form__cstmt_t v_291 = 0;
                              FX_CALL(
                                 _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0,
                                    block_stack_ref_0, &lbl_4, 0), _fx_catch_76);
                              FX_CALL(
                                 atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                                    fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_283, atom2cexp_0.fcv), _fx_catch_76);
                              FX_COPY_PTR(v_283.t0, &arrsz_exp_1);
                              FX_COPY_PTR(v_283.t1, &ccode_34);
                              FX_CALL(
                                 atom2cexp_0.fp(&v_278->hd, ccode_34, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                                    fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_284, atom2cexp_0.fcv), _fx_catch_76);
                              FX_COPY_PTR(v_284.t0, &a_exp_0);
                              FX_COPY_PTR(v_284.t1, &ccode_35);
                              FX_CALL(
                                 atom2cexp_0.fp(&v_279->hd, ccode_35, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                                    fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_285, atom2cexp_0.fcv), _fx_catch_76);
                              FX_COPY_PTR(v_285.t0, &b_exp_0);
                              FX_COPY_PTR(v_285.t1, &ccode_36);
                              FX_CALL(
                                 atom2cexp_0.fp(&v_280->hd, ccode_36, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                                    fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_286, atom2cexp_0.fcv), _fx_catch_76);
                              FX_COPY_PTR(v_286.t0, &delta_exp_0);
                              FX_COPY_PTR(v_286.t1, &ccode_37);
                              FX_CALL(
                                 atom2cexp_0.fp(&v_281->hd, ccode_37, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                                    fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_287, atom2cexp_0.fcv), _fx_catch_76);
                              FX_COPY_PTR(v_287.t0, &scale_exp_0);
                              FX_COPY_PTR(v_287.t1, &ccode_38);
                              FX_CALL(
                                 atom2cexp_0.fp(&v_282->hd, ccode_38, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                                    fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_288, atom2cexp_0.fcv), _fx_catch_76);
                              FX_COPY_PTR(v_288.t0, &shift_exp_0);
                              FX_COPY_PTR(v_288.t1, &ccode_39);
                              _fx_R9Ast__id_t v_292;
                              fx_str_t slit_78 = FX_MAKE_STR("FX_CHKIDX_RANGE");
                              FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_78, &v_292, 0), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_4, 0, true, &v_289), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(shift_exp_0, v_289, false, &v_289), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(scale_exp_0, v_289, false, &v_289), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(delta_exp_0, v_289, false, &v_289), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(b_exp_0, v_289, false, &v_289), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(a_exp_0, v_289, false, &v_289), _fx_catch_76);
                              FX_CALL(_fx_cons_LN14C_form__cexp_t(arrsz_exp_1, v_289, false, &v_289), _fx_catch_76);
                              FX_CALL(
                                 _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                                    &v_292, v_289, _fx_g20C_gen_code__CTypVoid, &kloc_0, &chk_1, 0), _fx_catch_76);
                              FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(chk_1, &v_290), _fx_catch_76);
                              FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_290, ccode_39, true, &v_291), _fx_catch_76);
                              _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_291, &v_1);

                           _fx_catch_76: ;
                              if (v_291) {
                                 _fx_free_LN15C_form__cstmt_t(&v_291);
                              }
                              if (v_290) {
                                 _fx_free_N15C_form__cstmt_t(&v_290);
                              }
                              if (chk_1) {
                                 _fx_free_N14C_form__cexp_t(&chk_1);
                              }
                              if (v_289) {
                                 _fx_free_LN14C_form__cexp_t(&v_289);
                              }
                              if (ccode_39) {
                                 _fx_free_LN15C_form__cstmt_t(&ccode_39);
                              }
                              if (shift_exp_0) {
                                 _fx_free_N14C_form__cexp_t(&shift_exp_0);
                              }
                              _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_288);
                              if (ccode_38) {
                                 _fx_free_LN15C_form__cstmt_t(&ccode_38);
                              }
                              if (scale_exp_0) {
                                 _fx_free_N14C_form__cexp_t(&scale_exp_0);
                              }
                              _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_287);
                              if (ccode_37) {
                                 _fx_free_LN15C_form__cstmt_t(&ccode_37);
                              }
                              if (delta_exp_0) {
                                 _fx_free_N14C_form__cexp_t(&delta_exp_0);
                              }
                              _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_286);
                              if (ccode_36) {
                                 _fx_free_LN15C_form__cstmt_t(&ccode_36);
                              }
                              if (b_exp_0) {
                                 _fx_free_N14C_form__cexp_t(&b_exp_0);
                              }
                              _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_285);
                              if (ccode_35) {
                                 _fx_free_LN15C_form__cstmt_t(&ccode_35);
                              }
                              if (a_exp_0) {
                                 _fx_free_N14C_form__cexp_t(&a_exp_0);
                              }
                              _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_284);
                              if (ccode_34) {
                                 _fx_free_LN15C_form__cstmt_t(&ccode_34);
                              }
                              if (arrsz_exp_1) {
                                 _fx_free_N14C_form__cexp_t(&arrsz_exp_1);
                              }
                              _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_283);
                              if (lbl_4) {
                                 _fx_free_N14C_form__cexp_t(&lbl_4);
                              }
                              goto _fx_endmatch_16;
                           }
                        }
                     }
                  }
               }
            }
         }
      }
      if (intr_0->tag == 12) {
         if (args_0 != 0) {
            if (args_0->tl == 0) {
               _fx_N14K_form__atom_t* v_293 = &args_0->hd;
               if (v_293->tag == 1) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_294 = {0};
                  _fx_N14C_form__cexp_t dst_exp_5 = 0;
                  _fx_LN15C_form__cstmt_t ccode_40 = 0;
                  _fx_N14C_form__cexp_t v_295 = 0;
                  _fx_LN14C_form__cexp_t v_296 = 0;
                  _fx_N14C_form__cexp_t v_297 = 0;
                  _fx_N15C_form__cstmt_t macro_0 = 0;
                  _fx_LN15C_form__cstmt_t v_298 = 0;
                  fx_str_t slit_79 = FX_MAKE_STR("make_fp_by_fcv");
                  FX_CALL(
                     _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                        dstexp_r_0, &slit_79, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_294, 0), _fx_catch_77);
                  FX_COPY_PTR(v_294.t0, &dst_exp_5);
                  FX_COPY_PTR(v_294.t1, &ccode_40);
                  FX_CALL(
                     _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&v_293->u.AtomId,
                        _fx_g23C_form__std_CTypVoidPtr, &kloc_0, &v_295, 0), _fx_catch_77);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_exp_5, 0, true, &v_296), _fx_catch_77);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_295, v_296, false, &v_296), _fx_catch_77);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g29C_form__std_FX_MAKE_FP_BY_FCV, v_296, _fx_g20C_gen_code__CTypVoid, &kloc_0, &v_297, 0),
                     _fx_catch_77);
                  FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_297, &macro_0), _fx_catch_77);
                  FX_CALL(_fx_cons_LN15C_form__cstmt_t(macro_0, ccode_40, true, &v_298), _fx_catch_77);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_298, &v_1);

               _fx_catch_77: ;
                  if (v_298) {
                     _fx_free_LN15C_form__cstmt_t(&v_298);
                  }
                  if (macro_0) {
                     _fx_free_N15C_form__cstmt_t(&macro_0);
                  }
                  if (v_297) {
                     _fx_free_N14C_form__cexp_t(&v_297);
                  }
                  if (v_296) {
                     _fx_free_LN14C_form__cexp_t(&v_296);
                  }
                  if (v_295) {
                     _fx_free_N14C_form__cexp_t(&v_295);
                  }
                  if (ccode_40) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_40);
                  }
                  if (dst_exp_5) {
                     _fx_free_N14C_form__cexp_t(&dst_exp_5);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_294);
                  goto _fx_endmatch_16;
               }
            }
         }
      }
      if (intr_0->tag == 13) {
         if (args_0 != 0) {
            _fx_LN14K_form__atom_t v_299 = args_0->tl;
            if (v_299 != 0) {
               _fx_LN14K_form__atom_t v_300 = v_299->tl;
               if (v_300 != 0) {
                  _fx_LN14K_form__atom_t v_301 = v_300->tl;
                  if (v_301 != 0) {
                     _fx_LN14K_form__atom_t v_302 = v_301->tl;
                     if (v_302 != 0) {
                        _fx_LN14K_form__atom_t v_303 = v_302->tl;
                        if (v_303 != 0) {
                           _fx_LN14K_form__atom_t v_304 = v_303->tl;
                           if (v_304 != 0) {
                              _fx_LN14K_form__atom_t v_305 = v_304->tl;
                              if (v_305 != 0) {
                                 _fx_LN14K_form__atom_t v_306 = v_305->tl;
                                 if (v_306 != 0) {
                                    _fx_LN14K_form__atom_t v_307 = v_306->tl;
                                    if (v_307 != 0) {
                                       _fx_LN14K_form__atom_t v_308 = v_307->tl;
                                       if (v_308 != 0) {
                                          _fx_LN14K_form__atom_t v_309 = v_308->tl;
                                          if (v_309 != 0) {
                                             _fx_LN14K_form__atom_t v_310 = v_309->tl;
                                             if (v_310 != 0) {
                                                _fx_LN14K_form__atom_t v_311 = v_310->tl;
                                                if (v_311 != 0) {
                                                   _fx_LN14K_form__atom_t v_312 = v_311->tl;
                                                   if (v_312 != 0) {
                                                      _fx_LN14K_form__atom_t v_313 = v_312->tl;
                                                      if (v_313 != 0) {
                                                         if (v_313->tl == 0) {
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_314 = {0};
                                                            _fx_N14C_form__cexp_t m1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_41 = 0;
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_315 = {0};
                                                            _fx_N14C_form__cexp_t t1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_42 = 0;
                                                            _fx_N14K_form__atom_t v_316 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_317 = {0};
                                                            _fx_N14C_form__cexp_t rs1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_43 = 0;
                                                            _fx_N14K_form__atom_t v_318 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_319 = {0};
                                                            _fx_N14C_form__cexp_t re1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_44 = 0;
                                                            _fx_N14K_form__atom_t v_320 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_321 = {0};
                                                            _fx_N14C_form__cexp_t rd1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_45 = 0;
                                                            _fx_N14K_form__atom_t v_322 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_323 = {0};
                                                            _fx_N14C_form__cexp_t cs1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_46 = 0;
                                                            _fx_N14K_form__atom_t v_324 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_325 = {0};
                                                            _fx_N14C_form__cexp_t ce1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_47 = 0;
                                                            _fx_N14K_form__atom_t v_326 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_327 = {0};
                                                            _fx_N14C_form__cexp_t cd1exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_48 = 0;
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_328 = {0};
                                                            _fx_N14C_form__cexp_t m2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_49 = 0;
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_329 = {0};
                                                            _fx_N14C_form__cexp_t t2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_50 = 0;
                                                            _fx_N14K_form__atom_t v_330 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_331 = {0};
                                                            _fx_N14C_form__cexp_t rs2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_51 = 0;
                                                            _fx_N14K_form__atom_t v_332 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_333 = {0};
                                                            _fx_N14C_form__cexp_t re2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_52 = 0;
                                                            _fx_N14K_form__atom_t v_334 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_335 = {0};
                                                            _fx_N14C_form__cexp_t rd2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_53 = 0;
                                                            _fx_N14K_form__atom_t v_336 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_337 = {0};
                                                            _fx_N14C_form__cexp_t cs2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_54 = 0;
                                                            _fx_N14K_form__atom_t v_338 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_339 = {0};
                                                            _fx_N14C_form__cexp_t ce2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_55 = 0;
                                                            _fx_N14K_form__atom_t v_340 = {0};
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_341 = {0};
                                                            _fx_N14C_form__cexp_t cd2exp_0 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_56 = 0;
                                                            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_342 = {0};
                                                            _fx_N14C_form__cexp_t dst_exp_6 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_57 = 0;
                                                            _fx_N14C_form__cexp_t v_343 = 0;
                                                            _fx_N14C_form__cexp_t v_344 = 0;
                                                            _fx_N14C_form__cexp_t v_345 = 0;
                                                            _fx_LN14C_form__cexp_t v_346 = 0;
                                                            _fx_N14C_form__cexp_t call_exp_1 = 0;
                                                            _fx_LN15C_form__cstmt_t ccode_58 = 0;
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_314, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_314.t0, &m1exp_0);
                                                            FX_COPY_PTR(v_314.t1, &ccode_41);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_299->hd, ccode_41, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_315, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_315.t0, &t1exp_0);
                                                            FX_COPY_PTR(v_315.t1, &ccode_42);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_300->hd, 0LL, &v_316, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_316, ccode_42, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_317, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_317.t0, &rs1exp_0);
                                                            FX_COPY_PTR(v_317.t1, &ccode_43);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_301->hd, -1LL, &v_318, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_318, ccode_43, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_319, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_319.t0, &re1exp_0);
                                                            FX_COPY_PTR(v_319.t1, &ccode_44);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_302->hd, 1LL, &v_320, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_320, ccode_44, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_321, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_321.t0, &rd1exp_0);
                                                            FX_COPY_PTR(v_321.t1, &ccode_45);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_303->hd, 0LL, &v_322, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_322, ccode_45, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_323, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_323.t0, &cs1exp_0);
                                                            FX_COPY_PTR(v_323.t1, &ccode_46);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_304->hd, -1LL, &v_324, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_324, ccode_46, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_325, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_325.t0, &ce1exp_0);
                                                            FX_COPY_PTR(v_325.t1, &ccode_47);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_305->hd, 1LL, &v_326, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_326, ccode_47, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_327, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_327.t0, &cd1exp_0);
                                                            FX_COPY_PTR(v_327.t1, &ccode_48);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_306->hd, ccode_48, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_328, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_328.t0, &m2exp_0);
                                                            FX_COPY_PTR(v_328.t1, &ccode_49);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_307->hd, ccode_49, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_329, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_329.t0, &t2exp_0);
                                                            FX_COPY_PTR(v_329.t1, &ccode_50);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_308->hd, 0LL, &v_330, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_330, ccode_50, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_331, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_331.t0, &rs2exp_0);
                                                            FX_COPY_PTR(v_331.t1, &ccode_51);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_309->hd, -1LL, &v_332, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_332, ccode_51, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_333, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_333.t0, &re2exp_0);
                                                            FX_COPY_PTR(v_333.t1, &ccode_52);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_310->hd, 1LL, &v_334, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_334, ccode_52, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_335, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_335.t0, &rd2exp_0);
                                                            FX_COPY_PTR(v_335.t1, &ccode_53);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_311->hd, 0LL, &v_336, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_336, ccode_53, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_337, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_337.t0, &cs2exp_0);
                                                            FX_COPY_PTR(v_337.t1, &ccode_54);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_312->hd, -1LL, &v_338, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_338, ccode_54, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_339, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_339.t0, &ce2exp_0);
                                                            FX_COPY_PTR(v_339.t1, &ccode_55);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
                                                                  &v_313->hd, 1LL, &v_340, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               atom2cexp_0.fp(&v_340, ccode_55, &kloc_0, block_stack_ref_0,
                                                                  defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                                                                  &v_341, atom2cexp_0.fcv), _fx_catch_78);
                                                            FX_COPY_PTR(v_341.t0, &cd2exp_0);
                                                            FX_COPY_PTR(v_341.t1, &ccode_56);
                                                            fx_str_t slit_80 = FX_MAKE_STR("gemm");
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                                                                  dstexp_r_0, &slit_80, ctyp_0, ccode_56, &kloc_0,
                                                                  block_stack_ref_0, km_idx_0, &v_342, 0), _fx_catch_78);
                                                            FX_COPY_PTR(v_342.t0, &dst_exp_6);
                                                            FX_COPY_PTR(v_342.t1, &ccode_57);
                                                            _fx_R9Ast__id_t v_347;
                                                            fx_str_t slit_81 = FX_MAKE_STR("fx_gemm");
                                                            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_81, &v_347, 0),
                                                               _fx_catch_78);
                                                            FX_CALL(
                                                               _fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(
                                                                  m1exp_0, &v_343, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               _fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(
                                                                  m2exp_0, &v_344, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               _fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(
                                                                  dst_exp_6, &v_345, 0), _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_345, 0, true, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(cd2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(cs2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(rd2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(re2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(rs2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(t2exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_344, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(cd1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(cs1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(rd1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(re1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(rs1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(t1exp_0, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_343, v_346, false, &v_346),
                                                               _fx_catch_78);
                                                            FX_CALL(
                                                               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                                                                  &v_347, v_346, _fx_g20C_gen_code__CTypVoid, &kloc_0,
                                                                  &call_exp_1, 0), _fx_catch_78);
                                                            FX_CALL(
                                                               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                                                                  call_exp_1, ccode_57, &kloc_0, block_stack_ref_0, &ccode_58,
                                                                  0), _fx_catch_78);
                                                            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_6,
                                                               ccode_58, &v_1);

                                                         _fx_catch_78: ;
                                                            if (ccode_58) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_58);
                                                            }
                                                            if (call_exp_1) {
                                                               _fx_free_N14C_form__cexp_t(&call_exp_1);
                                                            }
                                                            if (v_346) {
                                                               _fx_free_LN14C_form__cexp_t(&v_346);
                                                            }
                                                            if (v_345) {
                                                               _fx_free_N14C_form__cexp_t(&v_345);
                                                            }
                                                            if (v_344) {
                                                               _fx_free_N14C_form__cexp_t(&v_344);
                                                            }
                                                            if (v_343) {
                                                               _fx_free_N14C_form__cexp_t(&v_343);
                                                            }
                                                            if (ccode_57) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_57);
                                                            }
                                                            if (dst_exp_6) {
                                                               _fx_free_N14C_form__cexp_t(&dst_exp_6);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_342);
                                                            if (ccode_56) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_56);
                                                            }
                                                            if (cd2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&cd2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_341);
                                                            _fx_free_N14K_form__atom_t(&v_340);
                                                            if (ccode_55) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_55);
                                                            }
                                                            if (ce2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&ce2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_339);
                                                            _fx_free_N14K_form__atom_t(&v_338);
                                                            if (ccode_54) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_54);
                                                            }
                                                            if (cs2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&cs2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_337);
                                                            _fx_free_N14K_form__atom_t(&v_336);
                                                            if (ccode_53) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_53);
                                                            }
                                                            if (rd2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&rd2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_335);
                                                            _fx_free_N14K_form__atom_t(&v_334);
                                                            if (ccode_52) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_52);
                                                            }
                                                            if (re2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&re2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_333);
                                                            _fx_free_N14K_form__atom_t(&v_332);
                                                            if (ccode_51) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_51);
                                                            }
                                                            if (rs2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&rs2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_331);
                                                            _fx_free_N14K_form__atom_t(&v_330);
                                                            if (ccode_50) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_50);
                                                            }
                                                            if (t2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&t2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_329);
                                                            if (ccode_49) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_49);
                                                            }
                                                            if (m2exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&m2exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_328);
                                                            if (ccode_48) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_48);
                                                            }
                                                            if (cd1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&cd1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_327);
                                                            _fx_free_N14K_form__atom_t(&v_326);
                                                            if (ccode_47) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_47);
                                                            }
                                                            if (ce1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&ce1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_325);
                                                            _fx_free_N14K_form__atom_t(&v_324);
                                                            if (ccode_46) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_46);
                                                            }
                                                            if (cs1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&cs1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_323);
                                                            _fx_free_N14K_form__atom_t(&v_322);
                                                            if (ccode_45) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_45);
                                                            }
                                                            if (rd1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&rd1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_321);
                                                            _fx_free_N14K_form__atom_t(&v_320);
                                                            if (ccode_44) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_44);
                                                            }
                                                            if (re1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&re1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_319);
                                                            _fx_free_N14K_form__atom_t(&v_318);
                                                            if (ccode_43) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_43);
                                                            }
                                                            if (rs1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&rs1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_317);
                                                            _fx_free_N14K_form__atom_t(&v_316);
                                                            if (ccode_42) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_42);
                                                            }
                                                            if (t1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&t1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_315);
                                                            if (ccode_41) {
                                                               _fx_free_LN15C_form__cstmt_t(&ccode_41);
                                                            }
                                                            if (m1exp_0) {
                                                               _fx_free_N14C_form__cexp_t(&m1exp_0);
                                                            }
                                                            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_314);
                                                            goto _fx_endmatch_16;
                                                         }
                                                      }
                                                   }
                                                }
                                             }
                                          }
                                       }
                                    }
                                 }
                              }
                           }
                        }
                     }
                  }
               }
            }
         }
      }
      if (intr_0->tag == 16) {
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___1 = {0};
         _fx_LN14K_form__atom_t args_2 = 0;
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_348 = {0};
         _fx_LN14C_form__cexp_t cargs_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_59 = 0;
         fx_str_t fname_0 = {0};
         _fx_N14K_form__atom_t v_349 = {0};
         _fx_N14K_form__ktyp_t argtyp_0 = 0;
         fx_str_t prefix_0 = {0};
         fx_str_t suffix_0 = {0};
         fx_str_t fname_1 = {0};
         _fx_LN14C_form__cexp_t v_350 = 0;
         _fx_N14C_form__cexp_t call_f_0 = 0;
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_0, &__fold_result___1);
         FX_COPY_PTR(args_0, &args_2);
         _fx_LN14K_form__atom_t lst_3 = args_2;
         for (; lst_3; lst_3 = lst_3->tl) {
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_351 = {0};
            _fx_LN14C_form__cexp_t cargs_1 = 0;
            _fx_LN15C_form__cstmt_t ccode_60 = 0;
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_352 = {0};
            _fx_N14C_form__cexp_t c_exp_1 = 0;
            _fx_LN15C_form__cstmt_t ccode_61 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_353 = {0};
            _fx_N14K_form__atom_t* a_1 = &lst_3->hd;
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___1, &v_351);
            FX_COPY_PTR(v_351.t0, &cargs_1);
            FX_COPY_PTR(v_351.t1, &ccode_60);
            FX_CALL(
               atom2cexp_0.fp(a_1, ccode_60, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                  km_idx_0, &v_352, atom2cexp_0.fcv), _fx_catch_79);
            FX_COPY_PTR(v_352.t0, &c_exp_1);
            FX_COPY_PTR(v_352.t1, &ccode_61);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(c_exp_1, cargs_1, false, &cargs_1), _fx_catch_79);
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(cargs_1, ccode_61, &v_353);
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___1);
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_353, &__fold_result___1);

         _fx_catch_79: ;
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_353);
            if (ccode_61) {
               _fx_free_LN15C_form__cstmt_t(&ccode_61);
            }
            if (c_exp_1) {
               _fx_free_N14C_form__cexp_t(&c_exp_1);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_352);
            if (ccode_60) {
               _fx_free_LN15C_form__cstmt_t(&ccode_60);
            }
            if (cargs_1) {
               _fx_free_LN14C_form__cexp_t(&cargs_1);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_351);
            FX_CHECK_EXN(_fx_catch_80);
         }
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___1, &v_348);
         FX_COPY_PTR(v_348.t0, &cargs_0);
         FX_COPY_PTR(v_348.t1, &ccode_59);
         FX_CALL(_fx_M3AstFM2ppS1RM4id_t(&intr_0->u.IntrinMath, &fname_0, 0), _fx_catch_80);
         FX_CALL(_fx_M10C_gen_codeFM2hdN14K_form__atom_t1LN14K_form__atom_t(args_0, &v_349, 0), _fx_catch_80);
         FX_CALL(_fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(&v_349, &kloc_0, &argtyp_0, 0),
            _fx_catch_80);
         bool res_10;
         fx_str_t slit_82 = FX_MAKE_STR("floor");
         if (fx_streq(&fname_0, &slit_82)) {
            res_10 = true; goto _fx_endmatch_12;
         }
         fx_str_t slit_83 = FX_MAKE_STR("ceil");
         if (fx_streq(&fname_0, &slit_83)) {
            res_10 = true; goto _fx_endmatch_12;
         }
         fx_str_t slit_84 = FX_MAKE_STR("round ");
         if (fx_streq(&fname_0, &slit_84)) {
            res_10 = true; goto _fx_endmatch_12;
         }
         fx_str_t slit_85 = FX_MAKE_STR("min");
         if (fx_streq(&fname_0, &slit_85)) {
            res_10 = true; goto _fx_endmatch_12;
         }
         fx_str_t slit_86 = FX_MAKE_STR("max");
         if (fx_streq(&fname_0, &slit_86)) {
            res_10 = true; goto _fx_endmatch_12;
         }
         res_10 = false;

      _fx_endmatch_12: ;
         FX_CHECK_EXN(_fx_catch_80);
         if (res_10) {
            fx_str_t slit_87 = FX_MAKE_STR("fx_"); fx_copy_str(&slit_87, &prefix_0); goto _fx_endmatch_13;
         }
         fx_str_t slit_88 = FX_MAKE_STR("");
         fx_copy_str(&slit_88, &prefix_0);

      _fx_endmatch_13: ;
         FX_CHECK_EXN(_fx_catch_80);
         int tag_9 = FX_REC_VARIANT_TAG(argtyp_0);
         if (tag_9 == 5) {
            if (argtyp_0->u.KTypFloat == 32) {
               fx_str_t slit_89 = FX_MAKE_STR("f"); fx_copy_str(&slit_89, &suffix_0); goto _fx_endmatch_14;
            }
         }
         if (tag_9 == 1) {
            fx_str_t slit_90 = FX_MAKE_STR("i"); fx_copy_str(&slit_90, &suffix_0); goto _fx_endmatch_14;
         }
         fx_str_t slit_91 = FX_MAKE_STR("");
         fx_copy_str(&slit_91, &suffix_0);

      _fx_endmatch_14: ;
         FX_CHECK_EXN(_fx_catch_80);
         {
            const fx_str_t strs_17[] = { prefix_0, fname_0, suffix_0 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_17, 3, &fname_1), _fx_catch_80);
         }
         _fx_R9Ast__id_t v_354;
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&fname_1, &v_354, 0), _fx_catch_80);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(cargs_0, &v_350, 0), _fx_catch_80);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_354, v_350,
               ctyp_0, &kloc_0, &call_f_0, 0), _fx_catch_80);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, call_f_0, ccode_59, &v_1);

      _fx_catch_80: ;
         if (call_f_0) {
            _fx_free_N14C_form__cexp_t(&call_f_0);
         }
         if (v_350) {
            _fx_free_LN14C_form__cexp_t(&v_350);
         }
         FX_FREE_STR(&fname_1);
         FX_FREE_STR(&suffix_0);
         FX_FREE_STR(&prefix_0);
         if (argtyp_0) {
            _fx_free_N14K_form__ktyp_t(&argtyp_0);
         }
         _fx_free_N14K_form__atom_t(&v_349);
         FX_FREE_STR(&fname_0);
         if (ccode_59) {
            _fx_free_LN15C_form__cstmt_t(&ccode_59);
         }
         if (cargs_0) {
            _fx_free_LN14C_form__cexp_t(&cargs_0);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_348);
         if (args_2) {
            _fx_free_LN14K_form__atom_t(&args_2);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___1);
         goto _fx_endmatch_16;
      }
      if (args_0 != 0) {
         if (args_0->tl == 0) {
            if (intr_0->tag == 17) {
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_355 = {0};
               _fx_N14C_form__cexp_t c_exp_2 = 0;
               _fx_LN15C_form__cstmt_t ccode_62 = 0;
               _fx_N14K_form__ktyp_t argtyp_1 = 0;
               fx_str_t prefix_1 = {0};
               fx_str_t suffix_1 = {0};
               fx_str_t fname_2 = {0};
               _fx_LN14C_form__cexp_t v_356 = 0;
               _fx_N14C_form__cexp_t call_f_1 = 0;
               _fx_N14K_form__atom_t* arg_0 = &args_0->hd;
               FX_CALL(
                  atom2cexp_0.fp(arg_0, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                     km_idx_0, &v_355, atom2cexp_0.fcv), _fx_catch_85);
               FX_COPY_PTR(v_355.t0, &c_exp_2);
               FX_COPY_PTR(v_355.t1, &ccode_62);
               FX_CALL(
                  _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(arg_0, &kloc_0, &argtyp_1, 0),
                  _fx_catch_85);
               int tag_10 = FX_REC_VARIANT_TAG(argtyp_1);
               if (tag_10 == 1) {
                  fx_str_t slit_92 = FX_MAKE_STR("sat_I2"); fx_copy_str(&slit_92, &prefix_1); goto _fx_endmatch_15;
               }
               if (tag_10 == 5) {
                  if (argtyp_1->u.KTypFloat == 32) {
                     fx_str_t slit_93 = FX_MAKE_STR("sat_f2"); fx_copy_str(&slit_93, &prefix_1); goto _fx_endmatch_15;
                  }
               }
               if (tag_10 == 5) {
                  if (argtyp_1->u.KTypFloat == 64) {
                     fx_str_t slit_94 = FX_MAKE_STR("sat_d2"); fx_copy_str(&slit_94, &prefix_1); goto _fx_endmatch_15;
                  }
               }
               fx_str_t v_357 = {0};
               fx_str_t v_358 = {0};
               fx_exn_t v_359 = {0};
               FX_CALL(_fx_M6K_formFM6stringS1N14K_form__ktyp_t(argtyp_1, &v_357, 0), _fx_catch_81);
               fx_str_t slit_95 = FX_MAKE_STR("cgen: unsupported argument type ");
               fx_str_t slit_96 = FX_MAKE_STR(" of sat_...() intrinsic");
               {
                  const fx_str_t strs_18[] = { slit_95, v_357, slit_96 };
                  FX_CALL(fx_strjoin(0, 0, 0, strs_18, 3, &v_358), _fx_catch_81);
               }
               FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_358, &v_359, 0), _fx_catch_81);
               FX_THROW(&v_359, false, _fx_catch_81);

            _fx_catch_81: ;
               fx_free_exn(&v_359);
               FX_FREE_STR(&v_358);
               FX_FREE_STR(&v_357);

            _fx_endmatch_15: ;
               FX_CHECK_EXN(_fx_catch_85);
               int tag_11 = FX_REC_VARIANT_TAG(ctyp_0);
               if (tag_11 == 5) {
                  fx_str_t v_360 = {0};
                  FX_CALL(_fx_F6stringS1i(ctyp_0->u.CTypUInt, &v_360, 0), _fx_catch_82);
                  fx_str_t slit_97 = FX_MAKE_STR("u");
                  {
                     const fx_str_t strs_19[] = { slit_97, v_360 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_19, 2, &suffix_1), _fx_catch_82);
                  }

               _fx_catch_82: ;
                  FX_FREE_STR(&v_360);
               }
               else if (tag_11 == 4) {
                  fx_str_t v_361 = {0};
                  FX_CALL(_fx_F6stringS1i(ctyp_0->u.CTypSInt, &v_361, 0), _fx_catch_83);
                  fx_str_t slit_98 = FX_MAKE_STR("i");
                  {
                     const fx_str_t strs_20[] = { slit_98, v_361 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_20, 2, &suffix_1), _fx_catch_83);
                  }

               _fx_catch_83: ;
                  FX_FREE_STR(&v_361);
               }
               else {
                  _fx_T2SR9Ast__id_t v_362 = {0};
                  fx_str_t v_363 = {0};
                  fx_str_t v_364 = {0};
                  fx_exn_t v_365 = {0};
                  FX_CALL(_fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_362, 0),
                     _fx_catch_84);
                  FX_CALL(_fx_M10C_gen_codeFM6stringS1T2SR9Ast__id_t(&v_362, &v_363, 0), _fx_catch_84);
                  fx_str_t slit_99 = FX_MAKE_STR("cgen: unsupported return type ");
                  fx_str_t slit_100 = FX_MAKE_STR(" of sat_...() intrinsic");
                  {
                     const fx_str_t strs_21[] = { slit_99, v_363, slit_100 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_21, 3, &v_364), _fx_catch_84);
                  }
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_364, &v_365, 0), _fx_catch_84);
                  FX_THROW(&v_365, false, _fx_catch_84);

               _fx_catch_84: ;
                  fx_free_exn(&v_365);
                  FX_FREE_STR(&v_364);
                  FX_FREE_STR(&v_363);
                  _fx_free_T2SR9Ast__id_t(&v_362);
               }
               FX_CHECK_EXN(_fx_catch_85);
               {
                  const fx_str_t strs_22[] = { prefix_1, suffix_1 };
                  FX_CALL(fx_strjoin(0, 0, 0, strs_22, 2, &fname_2), _fx_catch_85);
               }
               _fx_R9Ast__id_t v_366;
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&fname_2, &v_366, 0), _fx_catch_85);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(c_exp_2, 0, true, &v_356), _fx_catch_85);
               FX_CALL(
                  _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_366,
                     v_356, ctyp_0, &kloc_0, &call_f_1, 0), _fx_catch_85);
               _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, call_f_1, ccode_62, &v_1);

            _fx_catch_85: ;
               if (call_f_1) {
                  _fx_free_N14C_form__cexp_t(&call_f_1);
               }
               if (v_356) {
                  _fx_free_LN14C_form__cexp_t(&v_356);
               }
               FX_FREE_STR(&fname_2);
               FX_FREE_STR(&suffix_1);
               FX_FREE_STR(&prefix_1);
               if (argtyp_1) {
                  _fx_free_N14K_form__ktyp_t(&argtyp_1);
               }
               if (ccode_62) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_62);
               }
               if (c_exp_2) {
                  _fx_free_N14C_form__cexp_t(&c_exp_2);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_355);
               goto _fx_endmatch_16;
            }
         }
      }
      if (intr_0->tag == 14) {
         if (args_0 != 0) {
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_367 = {0};
            _fx_N14C_form__cexp_t arr_exp_2 = 0;
            _fx_LN15C_form__cstmt_t ccode_63 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___2 = {0};
            _fx_LN14K_form__atom_t idxs_0 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_368 = {0};
            _fx_LN14C_form__cexp_t i_exps_0 = 0;
            _fx_LN15C_form__cstmt_t ccode_64 = 0;
            _fx_N14C_form__cexp_t v_369 = 0;
            _fx_LN14C_form__cexp_t i_exps_1 = 0;
            _fx_N14C_form__ctyp_t elem_ctyp_0 = 0;
            _fx_N14C_form__cexp_t v_370 = 0;
            _fx_LN14C_form__cexp_t v_371 = 0;
            _fx_LN14C_form__cexp_t v_372 = 0;
            _fx_N14C_form__ctyp_t v_373 = 0;
            _fx_N14C_form__cexp_t get_slice_exp_0 = 0;
            FX_CALL(
               atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                  km_idx_0, &v_367, atom2cexp_0.fcv), _fx_catch_88);
            FX_COPY_PTR(v_367.t0, &arr_exp_2);
            FX_COPY_PTR(v_367.t1, &ccode_63);
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_63, &__fold_result___2);
            FX_COPY_PTR(args_0->tl, &idxs_0);
            _fx_LN14K_form__atom_t lst_4 = idxs_0;
            for (; lst_4; lst_4 = lst_4->tl) {
               _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_374 = {0};
               _fx_LN14C_form__cexp_t i_exps_2 = 0;
               _fx_LN15C_form__cstmt_t ccode_65 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_375 = {0};
               _fx_N14C_form__cexp_t i_exp_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_66 = 0;
               _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_376 = {0};
               _fx_N14K_form__atom_t* i_4 = &lst_4->hd;
               _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___2, &v_374);
               FX_COPY_PTR(v_374.t0, &i_exps_2);
               FX_COPY_PTR(v_374.t1, &ccode_65);
               FX_CALL(
                  atom2cexp_0.fp(i_4, ccode_65, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                     km_idx_0, &v_375, atom2cexp_0.fcv), _fx_catch_86);
               FX_COPY_PTR(v_375.t0, &i_exp_0);
               FX_COPY_PTR(v_375.t1, &ccode_66);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_0, i_exps_2, false, &i_exps_2), _fx_catch_86);
               _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(i_exps_2, ccode_66, &v_376);
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___2);
               _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_376, &__fold_result___2);

            _fx_catch_86: ;
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_376);
               if (ccode_66) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_66);
               }
               if (i_exp_0) {
                  _fx_free_N14C_form__cexp_t(&i_exp_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_375);
               if (ccode_65) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_65);
               }
               if (i_exps_2) {
                  _fx_free_LN14C_form__cexp_t(&i_exps_2);
               }
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_374);
               FX_CHECK_EXN(_fx_catch_88);
            }
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___2, &v_368);
            FX_COPY_PTR(v_368.t0, &i_exps_0);
            FX_COPY_PTR(v_368.t1, &ccode_64);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_369, 0), _fx_catch_88);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_369, i_exps_0, true, &i_exps_1), _fx_catch_88);
            int_ ndims_1;
            FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(i_exps_1, &ndims_1, 0), _fx_catch_88);
            _fx_R9Ast__id_t fname_3;
            FX_CALL(_fx_M10C_gen_codeFM3nthR9Ast__id_t2LR9Ast__id_ti(_fx_g21C_form__std_FX_PTR_xD, ndims_1 - 1, &fname_3, 0),
               _fx_catch_88);
            if (FX_REC_VARIANT_TAG(ctyp_0) == 17) {
               FX_COPY_PTR(ctyp_0->u.CTypRawPtr.t1, &elem_ctyp_0);
            }
            else {
               _fx_T2SR9Ast__id_t v_377 = {0};
               fx_str_t v_378 = {0};
               fx_str_t v_379 = {0};
               fx_exn_t v_380 = {0};
               FX_CALL(_fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_377, 0),
                  _fx_catch_87);
               FX_CALL(_fx_M10C_gen_codeFM6stringS1T2SR9Ast__id_t(&v_377, &v_378, 0), _fx_catch_87);
               fx_str_t slit_101 = FX_MAKE_STR("cgen: unexpected return type ");
               fx_str_t slit_102 = FX_MAKE_STR(" of IntrinGetSlice() intrinsic; should be raw pointer");
               {
                  const fx_str_t strs_23[] = { slit_101, v_378, slit_102 };
                  FX_CALL(fx_strjoin(0, 0, 0, strs_23, 3, &v_379), _fx_catch_87);
               }
               FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_379, &v_380, 0), _fx_catch_87);
               FX_THROW(&v_380, false, _fx_catch_87);

            _fx_catch_87: ;
               fx_free_exn(&v_380);
               FX_FREE_STR(&v_379);
               FX_FREE_STR(&v_378);
               _fx_free_T2SR9Ast__id_t(&v_377);
            }
            FX_CHECK_EXN(_fx_catch_88);
            FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_0, &kloc_0, &v_370),
               _fx_catch_88);
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(i_exps_1, &v_371, 0), _fx_catch_88);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_2, v_371, true, &v_372), _fx_catch_88);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_370, v_372, false, &v_372), _fx_catch_88);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elem_ctyp_0, &v_373, 0), _fx_catch_88);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&fname_3,
                  v_372, v_373, &kloc_0, &get_slice_exp_0, 0), _fx_catch_88);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, get_slice_exp_0, ccode_64, &v_1);

         _fx_catch_88: ;
            if (get_slice_exp_0) {
               _fx_free_N14C_form__cexp_t(&get_slice_exp_0);
            }
            if (v_373) {
               _fx_free_N14C_form__ctyp_t(&v_373);
            }
            if (v_372) {
               _fx_free_LN14C_form__cexp_t(&v_372);
            }
            if (v_371) {
               _fx_free_LN14C_form__cexp_t(&v_371);
            }
            if (v_370) {
               _fx_free_N14C_form__cexp_t(&v_370);
            }
            if (elem_ctyp_0) {
               _fx_free_N14C_form__ctyp_t(&elem_ctyp_0);
            }
            if (i_exps_1) {
               _fx_free_LN14C_form__cexp_t(&i_exps_1);
            }
            if (v_369) {
               _fx_free_N14C_form__cexp_t(&v_369);
            }
            if (ccode_64) {
               _fx_free_LN15C_form__cstmt_t(&ccode_64);
            }
            if (i_exps_0) {
               _fx_free_LN14C_form__cexp_t(&i_exps_0);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_368);
            if (idxs_0) {
               _fx_free_LN14K_form__atom_t(&idxs_0);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___2);
            if (ccode_63) {
               _fx_free_LN15C_form__cstmt_t(&ccode_63);
            }
            if (arr_exp_2) {
               _fx_free_N14C_form__cexp_t(&arr_exp_2);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_367);
            goto _fx_endmatch_16;
         }
      }
      if (intr_0->tag == 15) {
         if (args_0 != 0) {
            _fx_LN14K_form__atom_t v_381 = args_0->tl;
            if (v_381 != 0) {
               if (v_381->tl == 0) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_382 = {0};
                  _fx_N14C_form__cexp_t ptr_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_67 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_383 = {0};
                  _fx_N14C_form__cexp_t i_exp_1 = 0;
                  _fx_LN15C_form__cstmt_t ccode_68 = 0;
                  _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_384 = {0};
                  _fx_N14C_form__cexp_t get_elem_exp_0 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(&args_0->hd, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_382, atom2cexp_0.fcv), _fx_catch_89);
                  FX_COPY_PTR(v_382.t0, &ptr_exp_0);
                  FX_COPY_PTR(v_382.t1, &ccode_67);
                  FX_CALL(
                     atom2cexp_0.fp(&v_381->hd, ccode_67, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_383, atom2cexp_0.fcv), _fx_catch_89);
                  FX_COPY_PTR(v_383.t0, &i_exp_1);
                  FX_COPY_PTR(v_383.t1, &ccode_68);
                  _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_384);
                  FX_CALL(
                     _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g24C_gen_code__COpArrayElem, ptr_exp_0, i_exp_1, &v_384, &get_elem_exp_0), _fx_catch_89);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, get_elem_exp_0, ccode_68, &v_1);

               _fx_catch_89: ;
                  if (get_elem_exp_0) {
                     _fx_free_N14C_form__cexp_t(&get_elem_exp_0);
                  }
                  _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_384);
                  if (ccode_68) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_68);
                  }
                  if (i_exp_1) {
                     _fx_free_N14C_form__cexp_t(&i_exp_1);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_383);
                  if (ccode_67) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_67);
                  }
                  if (ptr_exp_0) {
                     _fx_free_N14C_form__cexp_t(&ptr_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_382);
                  goto _fx_endmatch_16;
               }
            }
         }
      }
      fx_str_t v_385 = {0};
      fx_str_t v_386 = {0};
      fx_str_t v_387 = {0};
      fx_exn_t v_388 = {0};
      FX_CALL(_fx_M3AstFM6stringS1N13Ast__intrin_t(intr_0, &v_385, 0), _fx_catch_90);
      int_ v_389;
      FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14K_form__atom_t(args_0, &v_389, 0), _fx_catch_90);
      FX_CALL(_fx_F6stringS1i(v_389, &v_386, 0), _fx_catch_90);
      fx_str_t slit_103 = FX_MAKE_STR("cgen: unsupported KExpIntrin(");
      fx_str_t slit_104 = FX_MAKE_STR(", ...) or the wrong number of arguments (");
      fx_str_t slit_105 = FX_MAKE_STR(")");
      {
         const fx_str_t strs_24[] = { slit_103, v_385, slit_104, v_386, slit_105 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_24, 5, &v_387), _fx_catch_90);
      }
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_387, &v_388, 0), _fx_catch_90);
      FX_THROW(&v_388, false, _fx_catch_90);

   _fx_catch_90: ;
      fx_free_exn(&v_388);
      FX_FREE_STR(&v_387);
      FX_FREE_STR(&v_386);
      FX_FREE_STR(&v_385);

   _fx_endmatch_16: ;
      FX_CHECK_EXN(_fx_catch_91);

   _fx_catch_91: ;
      goto _fx_endmatch_49;
   }
   if (tag_0 == 10) {
      _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t
         process_seq_0 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_390 = {0};
      _fx_N14C_form__cexp_t e_8 = 0;
      _fx_LN15C_form__cstmt_t ccode_69 = 0;
      _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
         block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &process_seq_0);
      FX_CALL(
         process_seq_0.fp(kexp_0->u.KExpSeq.t0, ccode_0, block_stack_ref_0, defined_syms_ref_0, dstexp_r_0, dummy_exp_0,
            for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0,
            mod_sc_0, module_cleanup_ref_0, return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_390, process_seq_0.fcv),
         _fx_catch_92);
      FX_COPY_PTR(v_390.t0, &e_8);
      FX_COPY_PTR(v_390.t1, &ccode_69);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, e_8, ccode_69, &v_1);

   _fx_catch_92: ;
      if (ccode_69) {
         _fx_free_LN15C_form__cstmt_t(&ccode_69);
      }
      if (e_8) {
         _fx_free_N14C_form__cexp_t(&e_8);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_390);
      FX_FREE_FP(&process_seq_0);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 9) {
      _fx_N14C_form__cexp_t parent_lbl_0 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_391 = {0};
      _fx_N14C_form__cexp_t dst_exp_7 = 0;
      _fx_LN15C_form__cstmt_t ccode_70 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_392 = {0};
      _fx_LN15C_form__cstmt_t sync_ccode_0 = 0;
      _fx_rR23C_gen_code__block_ctx_t bctx_sync_0 = 0;
      _fx_LN15C_form__cstmt_t bctx_cleanup_0 = 0;
      _fx_LN15C_form__cstmt_t bctx_prologue_0 = 0;
      _fx_LN15C_form__cstmt_t epilogue_0 = 0;
      _fx_N15C_form__cstmt_t v_393 = 0;
      _fx_LN15C_form__cstmt_t v_394 = 0;
      _fx_LN15C_form__cstmt_t v_395 = 0;
      _fx_LN15C_form__cstmt_t sync_ccode_1 = 0;
      _fx_N15C_form__cstmt_t c_e_2 = 0;
      _fx_LN14C_form__cexp_t v_396 = 0;
      _fx_N14C_form__cexp_t check_exn_0 = 0;
      _fx_N15C_form__cstmt_t v_397 = 0;
      _fx_N15C_form__cstmt_t v_398 = 0;
      _fx_LN15C_form__cstmt_t v_399 = 0;
      _fx_T2R9Ast__id_tN14K_form__kexp_t* vcase_5 = &kexp_0->u.KExpSync;
      _fx_N14K_form__kexp_t e_9 = vcase_5->t1;
      FX_CALL(
         _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &parent_lbl_0, 0), _fx_catch_93);
      fx_str_t slit_106 = FX_MAKE_STR("t");
      FX_CALL(
         _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
            dstexp_r_0, &slit_106, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_391, 0), _fx_catch_93);
      FX_COPY_PTR(v_391.t0, &dst_exp_7);
      FX_COPY_PTR(v_391.t1, &ccode_70);
      FX_CALL(
         _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
            &_fx_g27C_gen_code__BlockKind_Block, &kloc_0, block_stack_ref_0, km_idx_0, 0), _fx_catch_93);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            e_9, dstexp_r_0, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0,
            fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0, return_used_ref_0,
            top_inline_ccode_ref_0, u1vals_0, &v_392, fx_fv), _fx_catch_93);
      FX_COPY_PTR(v_392.t1, &sync_ccode_0);
      FX_CALL(
         _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &bctx_sync_0, 0), _fx_catch_93);
      _fx_R23C_gen_code__block_ctx_t* v_400 = &bctx_sync_0->data;
      int_ bctx_label_used_0 = v_400->bctx_label_used;
      _fx_R9Ast__id_t bctx_label_0 = v_400->bctx_label;
      FX_COPY_PTR(v_400->bctx_cleanup, &bctx_cleanup_0);
      FX_COPY_PTR(v_400->bctx_prologue, &bctx_prologue_0);
      if (bctx_label_used_0 == 0) {
         FX_COPY_PTR(bctx_cleanup_0, &epilogue_0);
      }
      else {
         FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&bctx_label_0, &kloc_0, &v_393),
            _fx_catch_93);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_393, 0, true, &v_394), _fx_catch_93);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(bctx_cleanup_0, v_394,
               &epilogue_0, 0), _fx_catch_93);
      }
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(sync_ccode_0, bctx_prologue_0,
            &v_395, 0), _fx_catch_93);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(epilogue_0, v_395, &sync_ccode_1,
            0), _fx_catch_93);
      _fx_R10Ast__loc_t v_401;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(e_9, &v_401, 0), _fx_catch_93);
      FX_CALL(_fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(sync_ccode_1, &v_401, &c_e_2, 0),
         _fx_catch_93);
      FX_CALL(_fx_M10C_gen_codeFM13pop_block_ctxv2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0, 0), _fx_catch_93);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(parent_lbl_0, 0, true, &v_396), _fx_catch_93);
      FX_CALL(
         _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g24C_form__std_FX_CHECK_EXN, v_396, _fx_g20C_gen_code__CTypVoid, &kloc_0, &check_exn_0, 0), _fx_catch_93);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(check_exn_0, &v_397), _fx_catch_93);
      FX_CALL(_fx_M6C_formFM9CStmtSyncN15C_form__cstmt_t2R9Ast__id_tN15C_form__cstmt_t(&vcase_5->t0, c_e_2, &v_398),
         _fx_catch_93);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_398, ccode_70, true, &v_399), _fx_catch_93);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_397, v_399, false, &v_399), _fx_catch_93);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_7, v_399, &v_1);

   _fx_catch_93: ;
      if (v_399) {
         _fx_free_LN15C_form__cstmt_t(&v_399);
      }
      if (v_398) {
         _fx_free_N15C_form__cstmt_t(&v_398);
      }
      if (v_397) {
         _fx_free_N15C_form__cstmt_t(&v_397);
      }
      if (check_exn_0) {
         _fx_free_N14C_form__cexp_t(&check_exn_0);
      }
      if (v_396) {
         _fx_free_LN14C_form__cexp_t(&v_396);
      }
      if (c_e_2) {
         _fx_free_N15C_form__cstmt_t(&c_e_2);
      }
      if (sync_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&sync_ccode_1);
      }
      if (v_395) {
         _fx_free_LN15C_form__cstmt_t(&v_395);
      }
      if (v_394) {
         _fx_free_LN15C_form__cstmt_t(&v_394);
      }
      if (v_393) {
         _fx_free_N15C_form__cstmt_t(&v_393);
      }
      if (epilogue_0) {
         _fx_free_LN15C_form__cstmt_t(&epilogue_0);
      }
      if (bctx_prologue_0) {
         _fx_free_LN15C_form__cstmt_t(&bctx_prologue_0);
      }
      if (bctx_cleanup_0) {
         _fx_free_LN15C_form__cstmt_t(&bctx_cleanup_0);
      }
      if (bctx_sync_0) {
         _fx_free_rR23C_gen_code__block_ctx_t(&bctx_sync_0);
      }
      if (sync_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&sync_ccode_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_392);
      if (ccode_70) {
         _fx_free_LN15C_form__cstmt_t(&ccode_70);
      }
      if (dst_exp_7) {
         _fx_free_N14C_form__cexp_t(&dst_exp_7);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_391);
      if (parent_lbl_0) {
         _fx_free_N14C_form__cexp_t(&parent_lbl_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 11) {
      _fx_rNt6option1N14C_form__cexp_t v_402 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_403 = {0};
      _fx_N14C_form__cexp_t cc_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_71 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_404 = {0};
      _fx_N14C_form__cexp_t dst_exp_8 = 0;
      _fx_LN15C_form__cstmt_t ccode_72 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_405 = {0};
      _fx_LN15C_form__cstmt_t ccode1_0 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_406 = {0};
      _fx_LN15C_form__cstmt_t ccode2_0 = 0;
      _fx_N15C_form__cstmt_t c_e1_0 = 0;
      _fx_N15C_form__cstmt_t c_e2_0 = 0;
      _fx_N15C_form__cstmt_t v_407 = 0;
      _fx_LN15C_form__cstmt_t v_408 = 0;
      _fx_T4N14K_form__kexp_tN14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_6 = &kexp_0->u.KExpIf;
      _fx_N14K_form__kexp_t e2_0 = vcase_6->t2;
      _fx_N14K_form__kexp_t e1_0 = vcase_6->t1;
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_402), _fx_catch_94);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            vcase_6->t0, v_402, ccode_0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_403, fx_fv), _fx_catch_94);
      FX_COPY_PTR(v_403.t0, &cc_0);
      FX_COPY_PTR(v_403.t1, &ccode_71);
      fx_str_t slit_107 = FX_MAKE_STR("t");
      FX_CALL(
         _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
            dstexp_r_0, &slit_107, ctyp_0, ccode_71, &kloc_0, block_stack_ref_0, km_idx_0, &v_404, 0), _fx_catch_94);
      FX_COPY_PTR(v_404.t0, &dst_exp_8);
      FX_COPY_PTR(v_404.t1, &ccode_72);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            e1_0, dstexp_r_0, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0,
            fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0, return_used_ref_0,
            top_inline_ccode_ref_0, u1vals_0, &v_405, fx_fv), _fx_catch_94);
      FX_COPY_PTR(v_405.t1, &ccode1_0);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            e2_0, dstexp_r_0, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0,
            fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0, return_used_ref_0,
            top_inline_ccode_ref_0, u1vals_0, &v_406, fx_fv), _fx_catch_94);
      FX_COPY_PTR(v_406.t1, &ccode2_0);
      _fx_R10Ast__loc_t v_409;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(e1_0, &v_409, 0), _fx_catch_94);
      FX_CALL(_fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(ccode1_0, &v_409, &c_e1_0, 0),
         _fx_catch_94);
      _fx_R10Ast__loc_t v_410;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(e2_0, &v_410, 0), _fx_catch_94);
      FX_CALL(_fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(ccode2_0, &v_410, &c_e2_0, 0),
         _fx_catch_94);
      FX_CALL(
         _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(cc_0,
            c_e1_0, c_e2_0, &kloc_0, &v_407, 0), _fx_catch_94);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_407, ccode_72, true, &v_408), _fx_catch_94);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_8, v_408, &v_1);

   _fx_catch_94: ;
      if (v_408) {
         _fx_free_LN15C_form__cstmt_t(&v_408);
      }
      if (v_407) {
         _fx_free_N15C_form__cstmt_t(&v_407);
      }
      if (c_e2_0) {
         _fx_free_N15C_form__cstmt_t(&c_e2_0);
      }
      if (c_e1_0) {
         _fx_free_N15C_form__cstmt_t(&c_e1_0);
      }
      if (ccode2_0) {
         _fx_free_LN15C_form__cstmt_t(&ccode2_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_406);
      if (ccode1_0) {
         _fx_free_LN15C_form__cstmt_t(&ccode1_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_405);
      if (ccode_72) {
         _fx_free_LN15C_form__cstmt_t(&ccode_72);
      }
      if (dst_exp_8) {
         _fx_free_N14C_form__cexp_t(&dst_exp_8);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_404);
      if (ccode_71) {
         _fx_free_LN15C_form__cstmt_t(&ccode_71);
      }
      if (cc_0) {
         _fx_free_N14C_form__cexp_t(&cc_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_403);
      if (v_402) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_402);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 12) {
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___3 = {0};
      _fx_LN14K_form__atom_t args_3 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_411 = {0};
      _fx_LN14C_form__cexp_t args_4 = 0;
      _fx_LN15C_form__cstmt_t ccode_73 = 0;
      _fx_N15C_form__cinfo_t v_412 = {0};
      _fx_T2R9Ast__id_tN15C_form__cinfo_t v_413 = {0};
      _fx_N15C_form__cinfo_t ci_0 = {0};
      _fx_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t v_414 = {0};
      _fx_N14C_form__cexp_t f_exp_1 = 0;
      _fx_LN14C_form__cexp_t fv_args_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_74 = 0;
      _fx_LN14C_form__cexp_t v_415 = 0;
      _fx_LN14C_form__cexp_t args_5 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_416 = {0};
      _fx_N14C_form__cexp_t call_exp_2 = 0;
      _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t v_417 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_418 = {0};
      _fx_N14C_form__cexp_t dst_exp_9 = 0;
      _fx_LN15C_form__cstmt_t ccode_75 = 0;
      _fx_N14C_form__cexp_t v_419 = 0;
      _fx_LN14C_form__cexp_t v_420 = 0;
      _fx_LN14C_form__cexp_t args_6 = 0;
      _fx_N14C_form__cexp_t dst_exp_10 = 0;
      _fx_LN15C_form__cstmt_t ccode_76 = 0;
      _fx_LN14C_form__cexp_t v_421 = 0;
      _fx_LN14C_form__cexp_t args_7 = 0;
      _fx_N14C_form__ctyp_t fcall_rt_0 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_422 = {0};
      _fx_N14C_form__cexp_t fcall_exp_0 = 0;
      _fx_N15C_form__cstmt_t v_423 = 0;
      _fx_LN15C_form__cstmt_t v_424 = 0;
      _fx_LN15C_form__cstmt_t ccode_77 = 0;
      _fx_T3R9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_7 = &kexp_0->u.KExpCall;
      _fx_R9Ast__id_t* f_2 = &vcase_7->t0;
      _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_0, &__fold_result___3);
      FX_COPY_PTR(vcase_7->t1, &args_3);
      _fx_LN14K_form__atom_t lst_5 = args_3;
      for (; lst_5; lst_5 = lst_5->tl) {
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_425 = {0};
         _fx_LN14C_form__cexp_t args_8 = 0;
         _fx_LN15C_form__cstmt_t ccode_78 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_426 = {0};
         _fx_N14C_form__cexp_t carg_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_79 = 0;
         _fx_N14C_form__cexp_t carg_1 = 0;
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_427 = {0};
         _fx_N14K_form__atom_t* arg_1 = &lst_5->hd;
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___3, &v_425);
         FX_COPY_PTR(v_425.t0, &args_8);
         FX_COPY_PTR(v_425.t1, &ccode_78);
         FX_CALL(
            atom2cexp_0.fp(arg_1, ccode_78, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
               km_idx_0, &v_426, atom2cexp_0.fcv), _fx_catch_95);
         FX_COPY_PTR(v_426.t0, &carg_0);
         FX_COPY_PTR(v_426.t1, &ccode_79);
         FX_CALL(_fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(carg_0, &kloc_0, &carg_1, 0),
            _fx_catch_95);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(carg_1, args_8, false, &args_8), _fx_catch_95);
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(args_8, ccode_79, &v_427);
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___3);
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_427, &__fold_result___3);

      _fx_catch_95: ;
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_427);
         if (carg_1) {
            _fx_free_N14C_form__cexp_t(&carg_1);
         }
         if (ccode_79) {
            _fx_free_LN15C_form__cstmt_t(&ccode_79);
         }
         if (carg_0) {
            _fx_free_N14C_form__cexp_t(&carg_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_426);
         if (ccode_78) {
            _fx_free_LN15C_form__cstmt_t(&ccode_78);
         }
         if (args_8) {
            _fx_free_LN14C_form__cexp_t(&args_8);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_425);
         FX_CHECK_EXN(_fx_catch_100);
      }
      _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___3, &v_411);
      FX_COPY_PTR(v_411.t0, &args_4);
      FX_COPY_PTR(v_411.t1, &ccode_73);
      FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(f_2, &kloc_0, &v_412, 0), _fx_catch_100);
      if (v_412.tag == 5) {
         _fx_R17C_form__cdefexn_t v_428 = {0};
         _fx_N15C_form__cinfo_t v_429 = {0};
         _fx_copy_R17C_form__cdefexn_t(&v_412.u.CExn->data, &v_428);
         _fx_R9Ast__id_t* cexn_make_0 = &v_428.cexn_make;
         FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(cexn_make_0, &kloc_0, &v_429, 0),
            _fx_catch_96);
         _fx_make_T2R9Ast__id_tN15C_form__cinfo_t(cexn_make_0, &v_429, &v_413);

      _fx_catch_96: ;
         _fx_free_N15C_form__cinfo_t(&v_429);
         _fx_free_R17C_form__cdefexn_t(&v_428);
      }
      else {
         _fx_make_T2R9Ast__id_tN15C_form__cinfo_t(f_2, &v_412, &v_413);
      }
      FX_CHECK_EXN(_fx_catch_100);
      _fx_R9Ast__id_t f_3 = v_413.t0;
      _fx_copy_N15C_form__cinfo_t(&v_413.t1, &ci_0);
      int tag_12 = ci_0.tag;
      if (tag_12 == 3) {
         fx_str_t cf_cname_0 = {0};
         _fx_N14C_form__ctyp_t cf_rt_0 = 0;
         _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t cf_args_0 = 0;
         _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB v_430 = {0};
         _fx_N14C_form__cexp_t f_exp_2 = 0;
         _fx_LN14C_form__cexp_t fv_args_1 = 0;
         _fx_N14C_form__cexp_t v_431 = 0;
         _fx_N14C_form__cexp_t v_432 = 0;
         fx_str_t v_433 = {0};
         fx_str_t v_434 = {0};
         fx_exn_t v_435 = {0};
         _fx_R17C_form__cdeffun_t* v_436 = &ci_0.u.CFun->data;
         _fx_R10Ast__loc_t cf_loc_0 = v_436->cf_loc;
         fx_copy_str(&v_436->cf_cname, &cf_cname_0);
         _fx_R16Ast__fun_flags_t cf_flags_0 = v_436->cf_flags;
         FX_COPY_PTR(v_436->cf_rt, &cf_rt_0);
         FX_COPY_PTR(v_436->cf_args, &cf_args_0);
         FX_CALL(
            _fx_M10C_gen_codeFM33ensure_sym_is_defined_or_declaredv4R9Ast__id_tR10Ast__loc_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_t(
               &f_3, &kloc_0, defined_syms_ref_0, fwd_fdecls_ref_0, 0), _fx_catch_97);
         bool is_nothrow_0 = cf_flags_0.fun_flag_nothrow;
         FX_CALL(
            _fx_M10C_gen_codeFM15unpack_fun_argsT4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tB(
               cf_args_0, cf_rt_0, is_nothrow_0, &v_430, 0), _fx_catch_97);
         _fx_R9Ast__id_t ret_id_0 = v_430.t1;
         bool have_fv_arg_0 = v_430.t3;
         FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&f_3, &cf_loc_0, &f_exp_2, 0),
            _fx_catch_97);
         if (have_fv_arg_0) {
            if (!cf_flags_0.fun_flag_uses_fv) {
               FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_431, 0), _fx_catch_97);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_431, 0, true, &fv_args_1), _fx_catch_97);
            }
            else {
               _fx_R9Ast__id_t v_437;
               FX_CALL(
                  _fx_M10C_gen_codeFM9curr_funcR9Ast__id_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0, &v_437,
                     0), _fx_catch_97);
               bool res_11;
               FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&f_3, &v_437, &res_11, 0), _fx_catch_97);
               if (res_11) {
                  _fx_R9Ast__id_t v_438;
                  fx_str_t slit_108 = FX_MAKE_STR("fx_fv");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_108, &v_438, 0), _fx_catch_97);
                  FX_CALL(
                     _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&v_438,
                        _fx_g23C_form__std_CTypVoidPtr, &cf_loc_0, &v_432, 0), _fx_catch_97);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_432, 0, true, &fv_args_1), _fx_catch_97);
               }
               else {
                  FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&cf_cname_0, &v_433, 0), _fx_catch_97);
                  fx_str_t slit_109 = FX_MAKE_STR("cgen: looks like lambda lifting did not transform \'");
                  fx_str_t slit_110 =
                     FX_MAKE_STR(
                        "\' call correctly. Functions that access free variables must be called via closure (except for the case when function calls itself)");
                  {
                     const fx_str_t strs_25[] = { slit_109, v_433, slit_110 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_25, 3, &v_434), _fx_catch_97);
                  }
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_434, &v_435, 0), _fx_catch_97);
                  FX_THROW(&v_435, false, _fx_catch_97);
               }
            }
         }
         bool res_12;
         FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&ret_id_0, &_fx_g9Ast__noid, &res_12, 0), _fx_catch_97);
         _fx_make_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t(f_exp_2, res_12, fv_args_1, is_nothrow_0, ccode_73,
            &v_414);

      _fx_catch_97: ;
         fx_free_exn(&v_435);
         FX_FREE_STR(&v_434);
         FX_FREE_STR(&v_433);
         if (v_432) {
            _fx_free_N14C_form__cexp_t(&v_432);
         }
         if (v_431) {
            _fx_free_N14C_form__cexp_t(&v_431);
         }
         if (fv_args_1) {
            _fx_free_LN14C_form__cexp_t(&fv_args_1);
         }
         if (f_exp_2) {
            _fx_free_N14C_form__cexp_t(&f_exp_2);
         }
         _fx_free_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB(&v_430);
         if (cf_args_0) {
            _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&cf_args_0);
         }
         if (cf_rt_0) {
            _fx_free_N14C_form__ctyp_t(&cf_rt_0);
         }
         FX_FREE_STR(&cf_cname_0);
      }
      else if (tag_12 == 2) {
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_439 = {0};
         _fx_N14C_form__cexp_t fclo_exp_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_80 = 0;
         _fx_N14K_form__ktyp_t v_440 = 0;
         _fx_N14K_form__ktyp_t ftyp_0 = 0;
         _fx_N14C_form__ctyp_t cftyp_0 = 0;
         _fx_N14C_form__cexp_t f_exp_3 = 0;
         _fx_N14C_form__cexp_t v_441 = 0;
         _fx_LN14C_form__cexp_t fv_args_2 = 0;
         _fx_R16Ast__val_flags_t* cv_flags_0 = &ci_0.u.CVal.cv_flags;
         bool res_13;
         FX_CALL(_fx_M6K_formFM13is_val_globalB1R16Ast__val_flags_t(cv_flags_0, &res_13, 0), _fx_catch_98);
         bool t_7;
         if (res_13) {
            t_7 = true;
         }
         else {
            t_7 = cv_flags_0->val_flag_ctor > 0;
         }
         if (t_7) {
            FX_CALL(
               _fx_M10C_gen_codeFM33ensure_sym_is_defined_or_declaredv4R9Ast__id_tR10Ast__loc_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_t(
                  &f_3, &kloc_0, defined_syms_ref_0, fwd_fdecls_ref_0, 0), _fx_catch_98);
         }
         FX_CALL(
            _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
               &f_3, false, ccode_73, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
               &v_439, 0), _fx_catch_98);
         FX_COPY_PTR(v_439.t0, &fclo_exp_0);
         FX_COPY_PTR(v_439.t1, &ccode_80);
         FX_CALL(_fx_M6K_formFM12get_idk_ktypN14K_form__ktyp_t2R9Ast__id_tR10Ast__loc_t(&f_3, &kloc_0, &v_440, 0),
            _fx_catch_98);
         FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(v_440, &kloc_0, &ftyp_0, 0),
            _fx_catch_98);
         FX_CALL(_fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(ftyp_0, &kloc_0, &cftyp_0, 0),
            _fx_catch_98);
         _fx_R9Ast__id_t v_442;
         fx_str_t slit_111 = FX_MAKE_STR("fp");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_111, &v_442, 0), _fx_catch_98);
         FX_CALL(
            _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(fclo_exp_0, &v_442, cftyp_0,
               &f_exp_3, 0), _fx_catch_98);
         _fx_R9Ast__id_t v_443;
         fx_str_t slit_112 = FX_MAKE_STR("fcv");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_112, &v_443, 0), _fx_catch_98);
         FX_CALL(
            _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(fclo_exp_0, &v_443,
               _fx_g23C_form__std_CTypVoidPtr, &v_441, 0), _fx_catch_98);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_441, 0, true, &fv_args_2), _fx_catch_98);
         _fx_make_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t(f_exp_3, true, fv_args_2, false, ccode_80, &v_414);

      _fx_catch_98: ;
         if (fv_args_2) {
            _fx_free_LN14C_form__cexp_t(&fv_args_2);
         }
         if (v_441) {
            _fx_free_N14C_form__cexp_t(&v_441);
         }
         if (f_exp_3) {
            _fx_free_N14C_form__cexp_t(&f_exp_3);
         }
         if (cftyp_0) {
            _fx_free_N14C_form__ctyp_t(&cftyp_0);
         }
         if (ftyp_0) {
            _fx_free_N14K_form__ktyp_t(&ftyp_0);
         }
         if (v_440) {
            _fx_free_N14K_form__ktyp_t(&v_440);
         }
         if (ccode_80) {
            _fx_free_LN15C_form__cstmt_t(&ccode_80);
         }
         if (fclo_exp_0) {
            _fx_free_N14C_form__cexp_t(&fclo_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_439);
      }
      else {
         fx_str_t v_444 = {0};
         fx_str_t v_445 = {0};
         fx_str_t v_446 = {0};
         fx_exn_t v_447 = {0};
         FX_CALL(_fx_M6C_formFM7idc2strS2R9Ast__id_tR10Ast__loc_t(&f_3, &kloc_0, &v_444, 0), _fx_catch_99);
         FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_444, &v_445, 0), _fx_catch_99);
         fx_str_t slit_113 = FX_MAKE_STR("cgen: the called \'");
         fx_str_t slit_114 = FX_MAKE_STR("\' is not a function nor value");
         {
            const fx_str_t strs_26[] = { slit_113, v_445, slit_114 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_26, 3, &v_446), _fx_catch_99);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_446, &v_447, 0), _fx_catch_99);
         FX_THROW(&v_447, false, _fx_catch_99);

      _fx_catch_99: ;
         fx_free_exn(&v_447);
         FX_FREE_STR(&v_446);
         FX_FREE_STR(&v_445);
         FX_FREE_STR(&v_444);
      }
      FX_CHECK_EXN(_fx_catch_100);
      FX_COPY_PTR(v_414.t0, &f_exp_1);
      bool have_out_arg_0 = v_414.t1;
      FX_COPY_PTR(v_414.t2, &fv_args_0);
      bool is_nothrow_1 = v_414.t3;
      FX_COPY_PTR(v_414.t4, &ccode_74);
      bool t_8;
      if (!have_out_arg_0) {
         t_8 = FX_REC_VARIANT_TAG(ctyp_0) != 8;
      }
      else {
         t_8 = false;
      }
      if (t_8) {
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(fv_args_0, args_4, &v_415, 0),
            _fx_catch_100);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(v_415, &args_5, 0), _fx_catch_100);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_416);
         FX_CALL(
            _fx_M6C_formFM8CExpCallN14C_form__cexp_t3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               f_exp_1, args_5, &v_416, &call_exp_2), _fx_catch_100);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, call_exp_2, ccode_74, &v_1);
      }
      else {
         if (FX_REC_VARIANT_TAG(ctyp_0) == 8) {
            _fx_make_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(args_4, dummy_exp_0, ccode_74, &v_417);
         }
         else {
            fx_str_t slit_115 = FX_MAKE_STR("res");
            FX_CALL(
               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                  dstexp_r_0, &slit_115, ctyp_0, ccode_74, &kloc_0, block_stack_ref_0, km_idx_0, &v_418, 0), _fx_catch_100);
            FX_COPY_PTR(v_418.t0, &dst_exp_9);
            FX_COPY_PTR(v_418.t1, &ccode_75);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_9, &v_419, 0), _fx_catch_100);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_419, args_4, true, &v_420), _fx_catch_100);
            _fx_make_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(v_420, dst_exp_9, ccode_75, &v_417);
         }
         FX_COPY_PTR(v_417.t0, &args_6);
         FX_COPY_PTR(v_417.t1, &dst_exp_10);
         FX_COPY_PTR(v_417.t2, &ccode_76);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(fv_args_0, args_6, &v_421, 0),
            _fx_catch_100);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(v_421, &args_7, 0), _fx_catch_100);
         if (is_nothrow_1) {
            FX_COPY_PTR(_fx_g20C_gen_code__CTypVoid, &fcall_rt_0);
         }
         else {
            FX_COPY_PTR(_fx_g20C_gen_code__CTypCInt, &fcall_rt_0);
         }
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(fcall_rt_0, &kloc_0, &v_422);
         FX_CALL(
            _fx_M6C_formFM8CExpCallN14C_form__cexp_t3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               f_exp_1, args_7, &v_422, &fcall_exp_0), _fx_catch_100);
         if (is_nothrow_1) {
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(fcall_exp_0, &v_423), _fx_catch_100);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_423, ccode_76, true, &v_424), _fx_catch_100);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_10, v_424, &v_1);
         }
         else {
            FX_CALL(
               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  fcall_exp_0, ccode_76, &kloc_0, block_stack_ref_0, &ccode_77, 0), _fx_catch_100);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_10, ccode_77, &v_1);
         }
      }

   _fx_catch_100: ;
      if (ccode_77) {
         _fx_free_LN15C_form__cstmt_t(&ccode_77);
      }
      if (v_424) {
         _fx_free_LN15C_form__cstmt_t(&v_424);
      }
      if (v_423) {
         _fx_free_N15C_form__cstmt_t(&v_423);
      }
      if (fcall_exp_0) {
         _fx_free_N14C_form__cexp_t(&fcall_exp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_422);
      if (fcall_rt_0) {
         _fx_free_N14C_form__ctyp_t(&fcall_rt_0);
      }
      if (args_7) {
         _fx_free_LN14C_form__cexp_t(&args_7);
      }
      if (v_421) {
         _fx_free_LN14C_form__cexp_t(&v_421);
      }
      if (ccode_76) {
         _fx_free_LN15C_form__cstmt_t(&ccode_76);
      }
      if (dst_exp_10) {
         _fx_free_N14C_form__cexp_t(&dst_exp_10);
      }
      if (args_6) {
         _fx_free_LN14C_form__cexp_t(&args_6);
      }
      if (v_420) {
         _fx_free_LN14C_form__cexp_t(&v_420);
      }
      if (v_419) {
         _fx_free_N14C_form__cexp_t(&v_419);
      }
      if (ccode_75) {
         _fx_free_LN15C_form__cstmt_t(&ccode_75);
      }
      if (dst_exp_9) {
         _fx_free_N14C_form__cexp_t(&dst_exp_9);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_418);
      _fx_free_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(&v_417);
      if (call_exp_2) {
         _fx_free_N14C_form__cexp_t(&call_exp_2);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_416);
      if (args_5) {
         _fx_free_LN14C_form__cexp_t(&args_5);
      }
      if (v_415) {
         _fx_free_LN14C_form__cexp_t(&v_415);
      }
      if (ccode_74) {
         _fx_free_LN15C_form__cstmt_t(&ccode_74);
      }
      if (fv_args_0) {
         _fx_free_LN14C_form__cexp_t(&fv_args_0);
      }
      if (f_exp_1) {
         _fx_free_N14C_form__cexp_t(&f_exp_1);
      }
      _fx_free_T5N14C_form__cexp_tBLN14C_form__cexp_tBLN15C_form__cstmt_t(&v_414);
      _fx_free_N15C_form__cinfo_t(&ci_0);
      _fx_free_T2R9Ast__id_tN15C_form__cinfo_t(&v_413);
      _fx_free_N15C_form__cinfo_t(&v_412);
      if (ccode_73) {
         _fx_free_LN15C_form__cstmt_t(&ccode_73);
      }
      if (args_4) {
         _fx_free_LN14C_form__cexp_t(&args_4);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_411);
      if (args_3) {
         _fx_free_LN14K_form__atom_t(&args_3);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___3);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 13) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_448 = {0};
      _fx_N14C_form__cexp_t io_cexp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_81 = 0;
      _fx_N14C_form__cexp_t obj_cexp_0 = 0;
      _fx_N14C_form__cexp_t v_449 = 0;
      _fx_LN14C_form__cexp_t v_450 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___4 = {0};
      _fx_LN14K_form__atom_t args_9 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_451 = {0};
      _fx_LN14C_form__cexp_t args_10 = 0;
      _fx_LN15C_form__cstmt_t ccode_82 = 0;
      _fx_N14C_form__ctyp_t t_9 = 0;
      _fx_Nt6option1rR23C_form__cdefinterface_t v_452 = {0};
      _fx_rR23C_form__cdefinterface_t obj_iface_0 = 0;
      _fx_LT2R9Ast__id_tN14C_form__ctyp_t v_453 = 0;
      _fx_T2R9Ast__id_tN14C_form__ctyp_t v_454 = {0};
      _fx_N14C_form__ctyp_t mt_0 = 0;
      _fx_N14C_form__cexp_t vtbl_0 = 0;
      _fx_N14C_form__cexp_t mexp_0 = 0;
      _fx_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t v_455 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_456 = {0};
      _fx_N14C_form__cexp_t dst_exp_11 = 0;
      _fx_LN15C_form__cstmt_t ccode_83 = 0;
      _fx_N14C_form__cexp_t v_457 = 0;
      _fx_LN14C_form__cexp_t v_458 = 0;
      _fx_LN14C_form__cexp_t args_11 = 0;
      _fx_N14C_form__cexp_t dst_exp_12 = 0;
      _fx_LN15C_form__cstmt_t ccode_84 = 0;
      _fx_N14C_form__cexp_t v_459 = 0;
      _fx_LN14C_form__cexp_t args_12 = 0;
      _fx_LN14C_form__cexp_t v_460 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_461 = {0};
      _fx_N14C_form__cexp_t mcall_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_85 = 0;
      _fx_T4R9Ast__id_tiLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_8 = &kexp_0->u.KExpICall;
      FX_CALL(
         _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
            &vcase_8->t0, true, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
            &v_448, 0), _fx_catch_103);
      FX_COPY_PTR(v_448.t0, &io_cexp_0);
      FX_COPY_PTR(v_448.t1, &ccode_81);
      _fx_R9Ast__id_t v_462;
      fx_str_t slit_116 = FX_MAKE_STR("obj");
      FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_116, &v_462, 0), _fx_catch_103);
      FX_CALL(
         _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(io_cexp_0, &v_462,
            _fx_g23C_form__std_CTypVoidPtr, &obj_cexp_0, 0), _fx_catch_103);
      FX_CALL(_fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(obj_cexp_0, &kloc_0, &v_449, 0),
         _fx_catch_103);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(v_449, 0, true, &v_450), _fx_catch_103);
      _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(v_450, ccode_81, &__fold_result___4);
      FX_COPY_PTR(vcase_8->t2, &args_9);
      _fx_LN14K_form__atom_t lst_6 = args_9;
      for (; lst_6; lst_6 = lst_6->tl) {
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_463 = {0};
         _fx_LN14C_form__cexp_t args_13 = 0;
         _fx_LN15C_form__cstmt_t ccode_86 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_464 = {0};
         _fx_N14C_form__cexp_t carg_2 = 0;
         _fx_LN15C_form__cstmt_t ccode_87 = 0;
         _fx_N14C_form__cexp_t carg_3 = 0;
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_465 = {0};
         _fx_N14K_form__atom_t* arg_2 = &lst_6->hd;
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___4, &v_463);
         FX_COPY_PTR(v_463.t0, &args_13);
         FX_COPY_PTR(v_463.t1, &ccode_86);
         FX_CALL(
            atom2cexp_0.fp(arg_2, ccode_86, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
               km_idx_0, &v_464, atom2cexp_0.fcv), _fx_catch_101);
         FX_COPY_PTR(v_464.t0, &carg_2);
         FX_COPY_PTR(v_464.t1, &ccode_87);
         FX_CALL(_fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(carg_2, &kloc_0, &carg_3, 0),
            _fx_catch_101);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(carg_3, args_13, false, &args_13), _fx_catch_101);
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(args_13, ccode_87, &v_465);
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___4);
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_465, &__fold_result___4);

      _fx_catch_101: ;
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_465);
         if (carg_3) {
            _fx_free_N14C_form__cexp_t(&carg_3);
         }
         if (ccode_87) {
            _fx_free_LN15C_form__cstmt_t(&ccode_87);
         }
         if (carg_2) {
            _fx_free_N14C_form__cexp_t(&carg_2);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_464);
         if (ccode_86) {
            _fx_free_LN15C_form__cstmt_t(&ccode_86);
         }
         if (args_13) {
            _fx_free_LN14C_form__cexp_t(&args_13);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_463);
         FX_CHECK_EXN(_fx_catch_103);
      }
      _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___4, &v_451);
      FX_COPY_PTR(v_451.t0, &args_10);
      FX_COPY_PTR(v_451.t1, &ccode_82);
      FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(io_cexp_0, &t_9, 0), _fx_catch_103);
      FX_CALL(
         _fx_M6C_formFM18get_cinterface_optNt6option1rRM15cdefinterface_t2N14C_form__ctyp_tR10Ast__loc_t(t_9, &kloc_0, &v_452,
            0), _fx_catch_103);
      if (v_452.tag == 2) {
         FX_COPY_PTR(v_452.u.Some, &obj_iface_0);
      }
      else {
         _fx_T2SR9Ast__id_t v_466 = {0};
         fx_str_t v_467 = {0};
         fx_str_t v_468 = {0};
         fx_str_t v_469 = {0};
         fx_exn_t v_470 = {0};
         FX_CALL(_fx_M6C_formFM8ctyp2strT2SR9Ast__id_t2N14C_form__ctyp_tR10Ast__loc_t(t_9, &kloc_0, &v_466, 0), _fx_catch_102);
         fx_copy_str(&v_466.t0, &v_467);
         FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_467, &v_468, 0), _fx_catch_102);
         fx_str_t slit_117 = FX_MAKE_STR("the first parameter (of type \'");
         fx_str_t slit_118 = FX_MAKE_STR("\') of KExpICall is not an interface");
         {
            const fx_str_t strs_27[] = { slit_117, v_468, slit_118 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_27, 3, &v_469), _fx_catch_102);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_469, &v_470, 0), _fx_catch_102);
         FX_THROW(&v_470, false, _fx_catch_102);

      _fx_catch_102: ;
         fx_free_exn(&v_470);
         FX_FREE_STR(&v_469);
         FX_FREE_STR(&v_468);
         FX_FREE_STR(&v_467);
         _fx_free_T2SR9Ast__id_t(&v_466);
      }
      FX_CHECK_EXN(_fx_catch_103);
      FX_COPY_PTR(obj_iface_0->data.ci_all_methods, &v_453);
      FX_CALL(
         _fx_M10C_gen_codeFM3nthT2R9Ast__id_tN14C_form__ctyp_t2LT2R9Ast__id_tN14C_form__ctyp_ti(v_453, vcase_8->t1, &v_454, 0),
         _fx_catch_103);
      _fx_R9Ast__id_t mname_0 = v_454.t0;
      FX_COPY_PTR(v_454.t1, &mt_0);
      _fx_R9Ast__id_t v_471;
      fx_str_t slit_119 = FX_MAKE_STR("vtbl");
      FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_119, &v_471, 0), _fx_catch_103);
      FX_CALL(
         _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(io_cexp_0, &v_471,
            _fx_g23C_form__std_CTypVoidPtr, &vtbl_0, 0), _fx_catch_103);
      FX_CALL(
         _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(vtbl_0, &mname_0, mt_0,
            &mexp_0, 0), _fx_catch_103);
      if (FX_REC_VARIANT_TAG(ctyp_0) == 8) {
         _fx_make_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(args_10, dummy_exp_0, ccode_82, &v_455);
      }
      else {
         fx_str_t slit_120 = FX_MAKE_STR("res");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_120, ctyp_0, ccode_82, &kloc_0, block_stack_ref_0, km_idx_0, &v_456, 0), _fx_catch_103);
         FX_COPY_PTR(v_456.t0, &dst_exp_11);
         FX_COPY_PTR(v_456.t1, &ccode_83);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(dst_exp_11, &v_457, 0), _fx_catch_103);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_457, args_10, true, &v_458), _fx_catch_103);
         _fx_make_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(v_458, dst_exp_11, ccode_83, &v_455);
      }
      FX_COPY_PTR(v_455.t0, &args_11);
      FX_COPY_PTR(v_455.t1, &dst_exp_12);
      FX_COPY_PTR(v_455.t2, &ccode_84);
      FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_459, 0), _fx_catch_103);
      FX_CALL(_fx_cons_LN14C_form__cexp_t(v_459, args_11, true, &args_12), _fx_catch_103);
      FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(args_12, &v_460, 0), _fx_catch_103);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypCInt, &kloc_0, &v_461);
      FX_CALL(
         _fx_M6C_formFM8CExpCallN14C_form__cexp_t3N14C_form__cexp_tLN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(mexp_0,
            v_460, &v_461, &mcall_exp_0), _fx_catch_103);
      FX_CALL(
         _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
            mcall_exp_0, ccode_84, &kloc_0, block_stack_ref_0, &ccode_85, 0), _fx_catch_103);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_12, ccode_85, &v_1);

   _fx_catch_103: ;
      if (ccode_85) {
         _fx_free_LN15C_form__cstmt_t(&ccode_85);
      }
      if (mcall_exp_0) {
         _fx_free_N14C_form__cexp_t(&mcall_exp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_461);
      if (v_460) {
         _fx_free_LN14C_form__cexp_t(&v_460);
      }
      if (args_12) {
         _fx_free_LN14C_form__cexp_t(&args_12);
      }
      if (v_459) {
         _fx_free_N14C_form__cexp_t(&v_459);
      }
      if (ccode_84) {
         _fx_free_LN15C_form__cstmt_t(&ccode_84);
      }
      if (dst_exp_12) {
         _fx_free_N14C_form__cexp_t(&dst_exp_12);
      }
      if (args_11) {
         _fx_free_LN14C_form__cexp_t(&args_11);
      }
      if (v_458) {
         _fx_free_LN14C_form__cexp_t(&v_458);
      }
      if (v_457) {
         _fx_free_N14C_form__cexp_t(&v_457);
      }
      if (ccode_83) {
         _fx_free_LN15C_form__cstmt_t(&ccode_83);
      }
      if (dst_exp_11) {
         _fx_free_N14C_form__cexp_t(&dst_exp_11);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_456);
      _fx_free_T3LN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(&v_455);
      if (mexp_0) {
         _fx_free_N14C_form__cexp_t(&mexp_0);
      }
      if (vtbl_0) {
         _fx_free_N14C_form__cexp_t(&vtbl_0);
      }
      if (mt_0) {
         _fx_free_N14C_form__ctyp_t(&mt_0);
      }
      _fx_free_T2R9Ast__id_tN14C_form__ctyp_t(&v_454);
      if (v_453) {
         _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&v_453);
      }
      if (obj_iface_0) {
         _fx_free_rR23C_form__cdefinterface_t(&obj_iface_0);
      }
      _fx_free_Nt6option1rR23C_form__cdefinterface_t(&v_452);
      if (t_9) {
         _fx_free_N14C_form__ctyp_t(&t_9);
      }
      if (ccode_82) {
         _fx_free_LN15C_form__cstmt_t(&ccode_82);
      }
      if (args_10) {
         _fx_free_LN14C_form__cexp_t(&args_10);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_451);
      if (args_9) {
         _fx_free_LN14K_form__atom_t(&args_9);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___4);
      if (v_450) {
         _fx_free_LN14C_form__cexp_t(&v_450);
      }
      if (v_449) {
         _fx_free_N14C_form__cexp_t(&v_449);
      }
      if (obj_cexp_0) {
         _fx_free_N14C_form__cexp_t(&obj_cexp_0);
      }
      if (ccode_81) {
         _fx_free_LN15C_form__cstmt_t(&ccode_81);
      }
      if (io_cexp_0) {
         _fx_free_N14C_form__cexp_t(&io_cexp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_448);
      goto _fx_endmatch_49;
   }
   bool res_14;
   if (tag_0 == 14) {
      res_14 = true;
   }
   else if (tag_0 == 15) {
      res_14 = true;
   }
   else {
      res_14 = false;
   }
   FX_CHECK_EXN(_fx_cleanup);
   if (res_14) {
      _fx_T2LN14K_form__atom_tS v_472 = {0};
      _fx_LN14K_form__atom_t args_14 = 0;
      fx_str_t prefix_2 = {0};
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___5 = {0};
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_473 = {0};
      _fx_LN14C_form__cexp_t cargs_2 = 0;
      _fx_LN15C_form__cstmt_t ccode_88 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_474 = {0};
      _fx_N14C_form__cexp_t t_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_89 = 0;
      _fx_LN14C_form__cexp_t v_475 = 0;
      _fx_N14C_form__cexp_t v_476 = 0;
      _fx_LN14C_form__cexp_t v_477 = 0;
      _fx_LN14C_form__cexp_t v_478 = 0;
      _fx_N14C_form__cexp_t call_mktup_0 = 0;
      _fx_N15C_form__cstmt_t v_479 = 0;
      _fx_LN15C_form__cstmt_t v_480 = 0;
      _fx_LN14C_form__cexp_t v_481 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_482 = {0};
      _fx_N14C_form__cexp_t e0_0 = 0;
      _fx_R16Ast__val_flags_t v_483 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_484 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_485 = {0};
      _fx_N14C_form__cexp_t t_exp_1 = 0;
      _fx_LN15C_form__cstmt_t ccode_90 = 0;
      int tag_13 = FX_REC_VARIANT_TAG(kexp_0);
      if (tag_13 == 14) {
         fx_str_t slit_121 = FX_MAKE_STR("tup"); _fx_make_T2LN14K_form__atom_tS(kexp_0->u.KExpMkTuple.t0, &slit_121, &v_472);
      }
      else if (tag_13 == 15) {
         fx_str_t slit_122 = FX_MAKE_STR("rec"); _fx_make_T2LN14K_form__atom_tS(kexp_0->u.KExpMkRecord.t0, &slit_122, &v_472);
      }
      else {
         fx_exn_t v_486 = {0};
         fx_str_t slit_123 = FX_MAKE_STR("unexpected expression");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_123, &v_486, 0), _fx_catch_104);
         FX_THROW(&v_486, false, _fx_catch_104);

      _fx_catch_104: ;
         fx_free_exn(&v_486);
      }
      FX_CHECK_EXN(_fx_catch_106);
      FX_COPY_PTR(v_472.t0, &args_14);
      fx_copy_str(&v_472.t1, &prefix_2);
      _fx_R9Ast__id_t tcon_0;
      FX_CALL(
         _fx_M11C_gen_typesFM15get_constructorR9Ast__id_t3N14C_form__ctyp_tBR10Ast__loc_t(ctyp_0, false, &kloc_0, &tcon_0, 0),
         _fx_catch_106);
      _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_0, &__fold_result___5);
      _fx_LN14K_form__atom_t lst_7 = args_14;
      for (; lst_7; lst_7 = lst_7->tl) {
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_487 = {0};
         _fx_LN14C_form__cexp_t cargs_3 = 0;
         _fx_LN15C_form__cstmt_t ccode_91 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_488 = {0};
         _fx_N14C_form__cexp_t ca_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_92 = 0;
         _fx_N14C_form__cexp_t ca_1 = 0;
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_489 = {0};
         _fx_N14K_form__atom_t* a_2 = &lst_7->hd;
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5, &v_487);
         FX_COPY_PTR(v_487.t0, &cargs_3);
         FX_COPY_PTR(v_487.t1, &ccode_91);
         FX_CALL(
            atom2cexp_0.fp(a_2, ccode_91, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
               &v_488, atom2cexp_0.fcv), _fx_catch_105);
         FX_COPY_PTR(v_488.t0, &ca_0);
         FX_COPY_PTR(v_488.t1, &ccode_92);
         bool res_15;
         FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&tcon_0, &_fx_g9Ast__noid, &res_15, 0), _fx_catch_105);
         if (res_15) {
            FX_COPY_PTR(ca_0, &ca_1);
         }
         else {
            FX_CALL(_fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(ca_0, &kloc_0, &ca_1, 0),
               _fx_catch_105);
         }
         FX_CALL(_fx_cons_LN14C_form__cexp_t(ca_1, cargs_3, false, &cargs_3), _fx_catch_105);
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(cargs_3, ccode_92, &v_489);
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5);
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_489, &__fold_result___5);

      _fx_catch_105: ;
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_489);
         if (ca_1) {
            _fx_free_N14C_form__cexp_t(&ca_1);
         }
         if (ccode_92) {
            _fx_free_LN15C_form__cstmt_t(&ccode_92);
         }
         if (ca_0) {
            _fx_free_N14C_form__cexp_t(&ca_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_488);
         if (ccode_91) {
            _fx_free_LN15C_form__cstmt_t(&ccode_91);
         }
         if (cargs_3) {
            _fx_free_LN14C_form__cexp_t(&cargs_3);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_487);
         FX_CHECK_EXN(_fx_catch_106);
      }
      _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5, &v_473);
      FX_COPY_PTR(v_473.t0, &cargs_2);
      FX_COPY_PTR(v_473.t1, &ccode_88);
      bool res_16;
      FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&tcon_0, &_fx_g9Ast__noid, &res_16, 0), _fx_catch_106);
      if (res_16) {
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &prefix_2, ctyp_0, ccode_88, &kloc_0, block_stack_ref_0, km_idx_0, &v_474, 0), _fx_catch_106);
         FX_COPY_PTR(v_474.t0, &t_exp_0);
         FX_COPY_PTR(v_474.t1, &ccode_89);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(cargs_2, &v_475, 0), _fx_catch_106);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(t_exp_0, &v_476, 0), _fx_catch_106);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_476, 0, true, &v_477), _fx_catch_106);
         FX_CALL(_fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(v_475, v_477, &v_478, 0),
            _fx_catch_106);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&tcon_0,
               v_478, _fx_g20C_gen_code__CTypVoid, &kloc_0, &call_mktup_0, 0), _fx_catch_106);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_mktup_0, &v_479), _fx_catch_106);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_479, ccode_89, true, &v_480), _fx_catch_106);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, t_exp_0, v_480, &v_1);
      }
      else {
         _fx_R9Ast__id_t tup_2;
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &prefix_2, &tup_2, 0), _fx_catch_106);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(cargs_2, &v_481, 0), _fx_catch_106);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_482);
         FX_CALL(
            _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(v_481, &v_482, &e0_0),
            _fx_catch_106);
         FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_483, 0), _fx_catch_106);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(e0_0, &v_484);
         fx_str_t slit_124 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &tup_2, ctyp_0, &v_483, &slit_124, &v_484, ccode_88, &kloc_0, &v_485, 0), _fx_catch_106);
         FX_COPY_PTR(v_485.t0, &t_exp_1);
         FX_COPY_PTR(v_485.t1, &ccode_90);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, t_exp_1, ccode_90, &v_1);
      }

   _fx_catch_106: ;
      if (ccode_90) {
         _fx_free_LN15C_form__cstmt_t(&ccode_90);
      }
      if (t_exp_1) {
         _fx_free_N14C_form__cexp_t(&t_exp_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_485);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_484);
      _fx_free_R16Ast__val_flags_t(&v_483);
      if (e0_0) {
         _fx_free_N14C_form__cexp_t(&e0_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_482);
      if (v_481) {
         _fx_free_LN14C_form__cexp_t(&v_481);
      }
      if (v_480) {
         _fx_free_LN15C_form__cstmt_t(&v_480);
      }
      if (v_479) {
         _fx_free_N15C_form__cstmt_t(&v_479);
      }
      if (call_mktup_0) {
         _fx_free_N14C_form__cexp_t(&call_mktup_0);
      }
      if (v_478) {
         _fx_free_LN14C_form__cexp_t(&v_478);
      }
      if (v_477) {
         _fx_free_LN14C_form__cexp_t(&v_477);
      }
      if (v_476) {
         _fx_free_N14C_form__cexp_t(&v_476);
      }
      if (v_475) {
         _fx_free_LN14C_form__cexp_t(&v_475);
      }
      if (ccode_89) {
         _fx_free_LN15C_form__cstmt_t(&ccode_89);
      }
      if (t_exp_0) {
         _fx_free_N14C_form__cexp_t(&t_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_474);
      if (ccode_88) {
         _fx_free_LN15C_form__cstmt_t(&ccode_88);
      }
      if (cargs_2) {
         _fx_free_LN14C_form__cexp_t(&cargs_2);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_473);
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___5);
      FX_FREE_STR(&prefix_2);
      if (args_14) {
         _fx_free_LN14K_form__atom_t(&args_14);
      }
      _fx_free_T2LN14K_form__atom_tS(&v_472);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 16) {
      fx_str_t v_490 = {0};
      fx_str_t fp_prefix_0 = {0};
      _fx_N14C_form__cexp_t f_exp_4 = 0;
      _fx_N14C_form__cexp_t v_491 = 0;
      _fx_LN14C_form__cexp_t v_492 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_493 = {0};
      _fx_N14C_form__cexp_t e0_1 = 0;
      _fx_R16Ast__val_flags_t v_494 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_495 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_496 = {0};
      _fx_N14C_form__cexp_t fp_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_93 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___6 = {0};
      _fx_LN14K_form__atom_t args_15 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_497 = {0};
      _fx_LN14C_form__cexp_t cargs_4 = 0;
      _fx_LN15C_form__cstmt_t ccode_94 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_498 = {0};
      _fx_N14C_form__cexp_t fp_exp_1 = 0;
      _fx_LN15C_form__cstmt_t ccode_95 = 0;
      _fx_LN14C_form__cexp_t v_499 = 0;
      _fx_N14C_form__cexp_t v_500 = 0;
      _fx_LN14C_form__cexp_t v_501 = 0;
      _fx_LN14C_form__cexp_t v_502 = 0;
      _fx_N14C_form__cexp_t call_mkclo_0 = 0;
      _fx_N15C_form__cstmt_t v_503 = 0;
      _fx_LN15C_form__cstmt_t v_504 = 0;
      _fx_T4R9Ast__id_tR9Ast__id_tLN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_9 = &kexp_0->u.KExpMkClosure;
      _fx_LN14K_form__atom_t args_16 = vcase_9->t2;
      _fx_R9Ast__id_t* f_4 = &vcase_9->t1;
      _fx_R9Ast__id_t* make_fp_0 = &vcase_9->t0;
      FX_CALL(_fx_M3AstFM2ppS1RM4id_t(f_4, &v_490, 0), _fx_catch_108);
      fx_str_t slit_125 = FX_MAKE_STR("_fp");
      {
         const fx_str_t strs_28[] = { v_490, slit_125 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_28, 2, &fp_prefix_0), _fx_catch_108);
      }
      bool t_10;
      if (args_16 == 0) {
         FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(make_fp_0, &_fx_g9Ast__noid, &t_10, 0), _fx_catch_108);
      }
      else {
         t_10 = false;
      }
      if (t_10) {
         _fx_R9Ast__id_t fp_id_0;
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &fp_prefix_0, &fp_id_0, 0), _fx_catch_108);
         FX_CALL(
            _fx_M10C_gen_codeFM33ensure_sym_is_defined_or_declaredv4R9Ast__id_tR10Ast__loc_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_t(
               f_4, &kloc_0, defined_syms_ref_0, fwd_fdecls_ref_0, 0), _fx_catch_108);
         FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(f_4, &kloc_0, &f_exp_4, 0),
            _fx_catch_108);
         FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_491, 0), _fx_catch_108);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_491, 0, true, &v_492), _fx_catch_108);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(f_exp_4, v_492, false, &v_492), _fx_catch_108);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_493);
         FX_CALL(
            _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(v_492, &v_493, &e0_1),
            _fx_catch_108);
         FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_494, 0), _fx_catch_108);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(e0_1, &v_495);
         fx_str_t slit_126 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &fp_id_0, ctyp_0, &v_494, &slit_126, &v_495, ccode_0, &kloc_0, &v_496, 0), _fx_catch_108);
         FX_COPY_PTR(v_496.t0, &fp_exp_0);
         FX_COPY_PTR(v_496.t1, &ccode_93);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, fp_exp_0, ccode_93, &v_1);
      }
      else {
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_0, &__fold_result___6);
         FX_COPY_PTR(args_16, &args_15);
         _fx_LN14K_form__atom_t lst_8 = args_15;
         for (; lst_8; lst_8 = lst_8->tl) {
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_505 = {0};
            _fx_LN14C_form__cexp_t cargs_5 = 0;
            _fx_LN15C_form__cstmt_t ccode_96 = 0;
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_506 = {0};
            _fx_N14C_form__cexp_t ca_2 = 0;
            _fx_LN15C_form__cstmt_t ccode_97 = 0;
            _fx_N14C_form__cexp_t ca_3 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_507 = {0};
            _fx_N14K_form__atom_t* a_3 = &lst_8->hd;
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___6, &v_505);
            FX_COPY_PTR(v_505.t0, &cargs_5);
            FX_COPY_PTR(v_505.t1, &ccode_96);
            FX_CALL(
               atom2cexp_0.fp(a_3, ccode_96, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                  km_idx_0, &v_506, atom2cexp_0.fcv), _fx_catch_107);
            FX_COPY_PTR(v_506.t0, &ca_2);
            FX_COPY_PTR(v_506.t1, &ccode_97);
            FX_CALL(_fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(ca_2, &kloc_0, &ca_3, 0),
               _fx_catch_107);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ca_3, cargs_5, false, &cargs_5), _fx_catch_107);
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(cargs_5, ccode_97, &v_507);
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___6);
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_507, &__fold_result___6);

         _fx_catch_107: ;
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_507);
            if (ca_3) {
               _fx_free_N14C_form__cexp_t(&ca_3);
            }
            if (ccode_97) {
               _fx_free_LN15C_form__cstmt_t(&ccode_97);
            }
            if (ca_2) {
               _fx_free_N14C_form__cexp_t(&ca_2);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_506);
            if (ccode_96) {
               _fx_free_LN15C_form__cstmt_t(&ccode_96);
            }
            if (cargs_5) {
               _fx_free_LN14C_form__cexp_t(&cargs_5);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_505);
            FX_CHECK_EXN(_fx_catch_108);
         }
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___6, &v_497);
         FX_COPY_PTR(v_497.t0, &cargs_4);
         FX_COPY_PTR(v_497.t1, &ccode_94);
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &fp_prefix_0, ctyp_0, ccode_94, &kloc_0, block_stack_ref_0, km_idx_0, &v_498, 0), _fx_catch_108);
         FX_COPY_PTR(v_498.t0, &fp_exp_1);
         FX_COPY_PTR(v_498.t1, &ccode_95);
         FX_CALL(
            _fx_M10C_gen_codeFM33ensure_sym_is_defined_or_declaredv4R9Ast__id_tR10Ast__loc_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_t(
               make_fp_0, &kloc_0, defined_syms_ref_0, fwd_fdecls_ref_0, 0), _fx_catch_108);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(cargs_4, &v_499, 0), _fx_catch_108);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(fp_exp_1, &v_500, 0), _fx_catch_108);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_500, 0, true, &v_501), _fx_catch_108);
         FX_CALL(_fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(v_499, v_501, &v_502, 0),
            _fx_catch_108);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(make_fp_0,
               v_502, _fx_g20C_gen_code__CTypVoid, &kloc_0, &call_mkclo_0, 0), _fx_catch_108);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_mkclo_0, &v_503), _fx_catch_108);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_503, ccode_95, true, &v_504), _fx_catch_108);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, fp_exp_1, v_504, &v_1);
      }

   _fx_catch_108: ;
      if (v_504) {
         _fx_free_LN15C_form__cstmt_t(&v_504);
      }
      if (v_503) {
         _fx_free_N15C_form__cstmt_t(&v_503);
      }
      if (call_mkclo_0) {
         _fx_free_N14C_form__cexp_t(&call_mkclo_0);
      }
      if (v_502) {
         _fx_free_LN14C_form__cexp_t(&v_502);
      }
      if (v_501) {
         _fx_free_LN14C_form__cexp_t(&v_501);
      }
      if (v_500) {
         _fx_free_N14C_form__cexp_t(&v_500);
      }
      if (v_499) {
         _fx_free_LN14C_form__cexp_t(&v_499);
      }
      if (ccode_95) {
         _fx_free_LN15C_form__cstmt_t(&ccode_95);
      }
      if (fp_exp_1) {
         _fx_free_N14C_form__cexp_t(&fp_exp_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_498);
      if (ccode_94) {
         _fx_free_LN15C_form__cstmt_t(&ccode_94);
      }
      if (cargs_4) {
         _fx_free_LN14C_form__cexp_t(&cargs_4);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_497);
      if (args_15) {
         _fx_free_LN14K_form__atom_t(&args_15);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___6);
      if (ccode_93) {
         _fx_free_LN15C_form__cstmt_t(&ccode_93);
      }
      if (fp_exp_0) {
         _fx_free_N14C_form__cexp_t(&fp_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_496);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_495);
      _fx_free_R16Ast__val_flags_t(&v_494);
      if (e0_1) {
         _fx_free_N14C_form__cexp_t(&e0_1);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_493);
      if (v_492) {
         _fx_free_LN14C_form__cexp_t(&v_492);
      }
      if (v_491) {
         _fx_free_N14C_form__cexp_t(&v_491);
      }
      if (f_exp_4) {
         _fx_free_N14C_form__cexp_t(&f_exp_4);
      }
      FX_FREE_STR(&fp_prefix_0);
      FX_FREE_STR(&v_490);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 17) {
      _fx_LLT2BN14K_form__atom_t arows_0 = 0;
      _fx_T2iN14C_form__ctyp_t v_508 = {0};
      _fx_N14C_form__ctyp_t elem_ctyp_1 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_509 = {0};
      _fx_N14C_form__cexp_t arr_exp_3 = 0;
      _fx_LN15C_form__cstmt_t ccode_98 = 0;
      _fx_N14C_form__ctyp_t v_510 = 0;
      _fx_N14C_form__cexp_t scalars_exp_0 = 0;
      _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___7 = {0};
      _fx_LLT2BN14K_form__atom_t arows_1 = 0;
      _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_511 = {0};
      _fx_LN14C_form__cexp_t scalars_data_0 = 0;
      _fx_LN14C_form__cexp_t tags_data_0 = 0;
      _fx_LN14C_form__cexp_t arr_data_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_99 = 0;
      _fx_LN14C_form__cexp_t v_512 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_513 = {0};
      _fx_LN15C_form__cstmt_t sub_ccode_2 = 0;
      _fx_N14C_form__cexp_t v_514 = 0;
      _fx_LN14C_form__cexp_t v_515 = 0;
      _fx_LN14C_form__cexp_t v_516 = 0;
      _fx_LN14C_form__cexp_t tags_data_1 = 0;
      _fx_N14C_form__ctyp_t v_517 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_518 = {0};
      _fx_N14C_form__cexp_t tags_exp_0 = 0;
      _fx_LN15C_form__cstmt_t sub_ccode_3 = 0;
      _fx_LN14C_form__cexp_t v_519 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_520 = {0};
      _fx_N14C_form__cexp_t arr_data_exp_0 = 0;
      _fx_LN15C_form__cstmt_t sub_ccode_4 = 0;
      _fx_N14C_form__cexp_t v_521 = 0;
      _fx_LN14C_form__cexp_t v_522 = 0;
      _fx_N14C_form__cexp_t sizeof_elem_exp_0 = 0;
      _fx_T2BNt6option1N14C_form__cexp_t v_523 = {0};
      _fx_N14C_form__cexp_t free_f_exp_0 = 0;
      _fx_T2BNt6option1N14C_form__cexp_t v_524 = {0};
      _fx_N14C_form__cexp_t copy_f_exp_0 = 0;
      _fx_N14C_form__cexp_t v_525 = 0;
      _fx_N14C_form__cexp_t v_526 = 0;
      _fx_LN14C_form__cexp_t v_527 = 0;
      _fx_N14C_form__cexp_t call_mkarr_0 = 0;
      _fx_LN15C_form__cstmt_t sub_ccode_5 = 0;
      _fx_N15C_form__cstmt_t v_528 = 0;
      _fx_LN15C_form__cstmt_t ccode_100 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_529 = {0};
      _fx_N14C_form__cexp_t arr_exp_4 = 0;
      _fx_LN15C_form__cstmt_t ccode_101 = 0;
      _fx_LT2BN14K_form__atom_t v_530 = 0;
      _fx_Li shape_0 = 0;
      _fx_Li v_531 = 0;
      _fx_LN14C_form__cexp_t shape_1 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___8 = {0};
      _fx_LLT2BN14K_form__atom_t arows_2 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_532 = {0};
      _fx_LN14C_form__cexp_t data_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_102 = 0;
      _fx_LN19C_form__ctyp_attr_t v_533 = 0;
      _fx_N14C_form__ctyp_t shape_ctyp_0 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_534 = {0};
      _fx_N14C_form__cexp_t shape_arr_0 = 0;
      _fx_R16Ast__val_flags_t v_535 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_536 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_537 = {0};
      _fx_N14C_form__cexp_t shape_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode__0 = 0;
      _fx_LN14C_form__cexp_t v_538 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_539 = {0};
      _fx_N14C_form__cexp_t data_exp_0 = 0;
      _fx_LN15C_form__cstmt_t glob_data_ccode__0 = 0;
      _fx_R17C_form__cdefval_t data_cv_0 = {0};
      _fx_R16Ast__val_flags_t data_flags_0 = {0};
      _fx_R16Ast__val_flags_t v_540 = {0};
      _fx_R17C_form__cdefval_t v_541 = {0};
      _fx_N15C_form__cinfo_t v_542 = {0};
      _fx_Ta3N14C_form__cexp_t v_543 = {0};
      _fx_N14C_form__cexp_t sizeof_elem_exp_1 = 0;
      _fx_N14C_form__cexp_t free_f_exp_1 = 0;
      _fx_N14C_form__cexp_t copy_f_exp_1 = 0;
      _fx_N14C_form__cexp_t v_544 = 0;
      _fx_N14C_form__cexp_t v_545 = 0;
      _fx_LN14C_form__cexp_t v_546 = 0;
      _fx_N14C_form__cexp_t call_mkarr_1 = 0;
      _fx_LN15C_form__cstmt_t ccode__1 = 0;
      _fx_N15C_form__cstmt_t v_547 = 0;
      _fx_LN15C_form__cstmt_t v_548 = 0;
      _fx_LN14C_form__cexp_t v_549 = 0;
      _fx_N14C_form__cexp_t v_550 = 0;
      _fx_LN15C_form__cstmt_t ccode_103 = 0;
      _fx_T3BLLT2BN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_10 = &kexp_0->u.KExpMkArray;
      _fx_LLT2BN14K_form__atom_t arows_3 = vcase_10->t1;
      bool all_literals_0 = vcase_10->t0;
      bool have_expanded_0;
      if (!all_literals_0) {
         bool __fold_result___9 = false;
         FX_COPY_PTR(arows_3, &arows_0);
         _fx_LLT2BN14K_form__atom_t lst_9 = arows_0;
         for (; lst_9; lst_9 = lst_9->tl) {
            _fx_LT2BN14K_form__atom_t arow_0 = lst_9->hd;
            bool __fold_result___10 = false;
            _fx_LT2BN14K_form__atom_t lst_10 = arow_0;
            for (; lst_10; lst_10 = lst_10->tl) {
               _fx_T2BN14K_form__atom_t* __pat___0 = &lst_10->hd;
               if (__pat___0->t0) {
                  __fold_result___10 = true; FX_BREAK(_fx_catch_109);
               }

            _fx_catch_109: ;
               FX_CHECK_BREAK();
               FX_CHECK_EXN(_fx_catch_110);
            }
            if (__fold_result___10) {
               __fold_result___9 = true; FX_BREAK(_fx_catch_110);
            }

         _fx_catch_110: ;
            FX_CHECK_BREAK();
            FX_CHECK_EXN(_fx_catch_126);
         }
         have_expanded_0 = __fold_result___9;
      }
      else {
         have_expanded_0 = false;
      }
      if (FX_REC_VARIANT_TAG(ctyp_0) == 19) {
         _fx_T2iN14C_form__ctyp_t* vcase_11 = &ctyp_0->u.CTypArray;
         _fx_make_T2iN14C_form__ctyp_t(vcase_11->t0, vcase_11->t1, &v_508);
      }
      else {
         fx_exn_t v_551 = {0};
         fx_str_t slit_127 = FX_MAKE_STR("cgen: invalid output type of array construction expression");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_127, &v_551, 0), _fx_catch_111);
         FX_THROW(&v_551, false, _fx_catch_111);

      _fx_catch_111: ;
         fx_free_exn(&v_551);
      }
      FX_CHECK_EXN(_fx_catch_126);
      int_ dims_0 = v_508.t0;
      FX_COPY_PTR(v_508.t1, &elem_ctyp_1);
      if (have_expanded_0) {
         fx_str_t slit_128 = FX_MAKE_STR("arr");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_128, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_509, 0), _fx_catch_126);
         FX_COPY_PTR(v_509.t0, &arr_exp_3);
         FX_COPY_PTR(v_509.t1, &ccode_98);
         _fx_R9Ast__id_t scalars_id_0;
         fx_str_t slit_129 = FX_MAKE_STR("scalars");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_129, &scalars_id_0, 0), _fx_catch_126);
         FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elem_ctyp_1, &v_510, 0), _fx_catch_126);
         FX_CALL(
            _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&scalars_id_0, v_510,
               &kloc_0, &scalars_exp_0, 0), _fx_catch_126);
         _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(0, 0, 0, 0, ccode_98,
            &__fold_result___7);
         FX_COPY_PTR(arows_3, &arows_1);
         _fx_LLT2BN14K_form__atom_t lst_11 = arows_1;
         for (; lst_11; lst_11 = lst_11->tl) {
            _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_552 = {0};
            _fx_LN14C_form__cexp_t scalars_data_1 = 0;
            _fx_LN14C_form__cexp_t tags_data_2 = 0;
            _fx_LN14C_form__cexp_t arr_data_1 = 0;
            _fx_LN15C_form__cstmt_t ccode_104 = 0;
            _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___11 = {0};
            _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_553 = {0};
            _fx_LN14C_form__cexp_t scalars_data_2 = 0;
            _fx_LN14C_form__cexp_t tags_data_3 = 0;
            _fx_LN14C_form__cexp_t arr_data_2 = 0;
            _fx_LN15C_form__cstmt_t ccode_105 = 0;
            _fx_N14C_form__cexp_t v_554 = 0;
            _fx_LN14C_form__cexp_t v_555 = 0;
            _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_556 = {0};
            _fx_LT2BN14K_form__atom_t arow_1 = lst_11->hd;
            _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___7, &v_552);
            FX_COPY_PTR(v_552.t1, &scalars_data_1);
            FX_COPY_PTR(v_552.t2, &tags_data_2);
            FX_COPY_PTR(v_552.t3, &arr_data_1);
            FX_COPY_PTR(v_552.t4, &ccode_104);
            _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(v_552.t0, scalars_data_1,
               tags_data_2, arr_data_1, ccode_104, &__fold_result___11);
            _fx_LT2BN14K_form__atom_t lst_12 = arow_1;
            for (; lst_12; lst_12 = lst_12->tl) {
               _fx_N14K_form__atom_t a_4 = {0};
               _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_557 = {0};
               _fx_LN14C_form__cexp_t scalars_data_3 = 0;
               _fx_LN14C_form__cexp_t tags_data_4 = 0;
               _fx_LN14C_form__cexp_t arr_data_3 = 0;
               _fx_LN15C_form__cstmt_t ccode_106 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_558 = {0};
               _fx_N14C_form__cexp_t e_10 = 0;
               _fx_LN15C_form__cstmt_t ccode_107 = 0;
               _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_559 = {0};
               _fx_N14K_form__ktyp_t elem_ktyp_0 = 0;
               _fx_N14K_form__ktyp_t v_560 = 0;
               _fx_T2iN14C_form__cexp_t v_561 = {0};
               _fx_N14C_form__cexp_t elem_ptr_0 = 0;
               _fx_N14C_form__cexp_t v_562 = 0;
               _fx_LN14C_form__cexp_t v_563 = 0;
               _fx_LN14C_form__cexp_t v_564 = 0;
               _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t v_565 = {0};
               _fx_LN14C_form__cexp_t scalars_data_4 = 0;
               _fx_N14C_form__cexp_t arr_data_elem_0 = 0;
               _fx_N14C_form__cexp_t v_566 = 0;
               _fx_LN14C_form__cexp_t v_567 = 0;
               _fx_LN14C_form__cexp_t v_568 = 0;
               _fx_T2BN14K_form__atom_t* __pat___1 = &lst_12->hd;
               _fx_copy_N14K_form__atom_t(&__pat___1->t1, &a_4);
               _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___11,
                  &v_557);
               int_ nscalars_0 = v_557.t0;
               FX_COPY_PTR(v_557.t1, &scalars_data_3);
               FX_COPY_PTR(v_557.t2, &tags_data_4);
               FX_COPY_PTR(v_557.t3, &arr_data_3);
               FX_COPY_PTR(v_557.t4, &ccode_106);
               FX_CALL(
                  atom2cexp_0.fp(&a_4, ccode_106, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                     km_idx_0, &v_558, atom2cexp_0.fcv), _fx_catch_117);
               FX_COPY_PTR(v_558.t0, &e_10);
               FX_COPY_PTR(v_558.t1, &ccode_107);
               if (__pat___1->t0) {
                  FX_CALL(
                     _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(&a_4, &kloc_0, &elem_ktyp_0,
                        0), _fx_catch_117);
                  FX_CALL(
                     _fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(elem_ktyp_0, &kloc_0, &v_560,
                        0), _fx_catch_117);
                  int tag_14 = FX_REC_VARIANT_TAG(v_560);
                  if (tag_14 == 17) {
                     _fx_N14C_form__cexp_t v_569 = 0;
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_10, &v_569, 0), _fx_catch_112);
                     _fx_make_T2iN14C_form__cexp_t(v_560->u.KTypArray.t0, v_569, &v_561);

                  _fx_catch_112: ;
                     if (v_569) {
                        _fx_free_N14C_form__cexp_t(&v_569);
                     }
                  }
                  else if (tag_14 == 19) {
                     _fx_make_T2iN14C_form__cexp_t(100, e_10, &v_561);
                  }
                  else if (tag_14 == 18) {
                     _fx_N14C_form__cexp_t v_570 = 0;
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_10, &v_570, 0), _fx_catch_113);
                     _fx_make_T2iN14C_form__cexp_t(110, v_570, &v_561);

                  _fx_catch_113: ;
                     if (v_570) {
                        _fx_free_N14C_form__cexp_t(&v_570);
                     }
                  }
                  else {
                     fx_str_t v_571 = {0};
                     fx_str_t v_572 = {0};
                     fx_str_t v_573 = {0};
                     fx_exn_t v_574 = {0};
                     FX_CALL(_fx_M6K_formFM8atom2strS1N14K_form__atom_t(&a_4, &v_571, 0), _fx_catch_114);
                     FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_571, &v_572, 0), _fx_catch_114);
                     fx_str_t slit_130 = FX_MAKE_STR("cgen: the expanded structure ");
                     fx_str_t slit_131 = FX_MAKE_STR(" is not an array, vector or list");
                     {
                        const fx_str_t strs_29[] = { slit_130, v_572, slit_131 };
                        FX_CALL(fx_strjoin(0, 0, 0, strs_29, 3, &v_573), _fx_catch_114);
                     }
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_573, &v_574, 0), _fx_catch_114);
                     FX_THROW(&v_574, false, _fx_catch_114);

                  _fx_catch_114: ;
                     fx_free_exn(&v_574);
                     FX_FREE_STR(&v_573);
                     FX_FREE_STR(&v_572);
                     FX_FREE_STR(&v_571);
                  }
                  FX_CHECK_EXN(_fx_catch_117);
                  int_ tag_15 = v_561.t0;
                  FX_COPY_PTR(v_561.t1, &elem_ptr_0);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(tag_15, &kloc_0, &v_562, 0),
                     _fx_catch_117);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_562, tags_data_4, true, &v_563), _fx_catch_117);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(elem_ptr_0, arr_data_3, true, &v_564), _fx_catch_117);
                  _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(nscalars_0,
                     scalars_data_3, v_563, v_564, ccode_107, &v_559);
               }
               else {
                  if (FX_REC_VARIANT_TAG(e_10) == 1) {
                     _fx_N14C_form__cexp_t v_575 = 0;
                     FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_10, &v_575, 0), _fx_catch_115);
                     _fx_make_T3iLN14C_form__cexp_tN14C_form__cexp_t(nscalars_0, scalars_data_3, v_575, &v_565);

                  _fx_catch_115: ;
                     if (v_575) {
                        _fx_free_N14C_form__cexp_t(&v_575);
                     }
                  }
                  else {
                     _fx_LN14C_form__cexp_t v_576 = 0;
                     _fx_N14C_form__cexp_t v_577 = 0;
                     _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_578 = {0};
                     _fx_N14C_form__cexp_t v_579 = 0;
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(e_10, scalars_data_3, true, &v_576), _fx_catch_116);
                     FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(nscalars_0, &kloc_0, &v_577, 0),
                        _fx_catch_116);
                     _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g23C_form__std_CTypVoidPtr, &kloc_0, &v_578);
                     FX_CALL(
                        _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g18C_gen_code__COpAdd, scalars_exp_0, v_577, &v_578, &v_579), _fx_catch_116);
                     _fx_make_T3iLN14C_form__cexp_tN14C_form__cexp_t(nscalars_0 + 1, v_576, v_579, &v_565);

                  _fx_catch_116: ;
                     if (v_579) {
                        _fx_free_N14C_form__cexp_t(&v_579);
                     }
                     _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_578);
                     if (v_577) {
                        _fx_free_N14C_form__cexp_t(&v_577);
                     }
                     if (v_576) {
                        _fx_free_LN14C_form__cexp_t(&v_576);
                     }
                  }
                  FX_CHECK_EXN(_fx_catch_117);
                  int_ nscalars_1 = v_565.t0;
                  FX_COPY_PTR(v_565.t1, &scalars_data_4);
                  FX_COPY_PTR(v_565.t2, &arr_data_elem_0);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_566, 0), _fx_catch_117);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_566, tags_data_4, true, &v_567), _fx_catch_117);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_data_elem_0, arr_data_3, true, &v_568), _fx_catch_117);
                  _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(nscalars_1,
                     scalars_data_4, v_567, v_568, ccode_107, &v_559);
               }
               _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___11);
               _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_559,
                  &__fold_result___11);

            _fx_catch_117: ;
               if (v_568) {
                  _fx_free_LN14C_form__cexp_t(&v_568);
               }
               if (v_567) {
                  _fx_free_LN14C_form__cexp_t(&v_567);
               }
               if (v_566) {
                  _fx_free_N14C_form__cexp_t(&v_566);
               }
               if (arr_data_elem_0) {
                  _fx_free_N14C_form__cexp_t(&arr_data_elem_0);
               }
               if (scalars_data_4) {
                  _fx_free_LN14C_form__cexp_t(&scalars_data_4);
               }
               _fx_free_T3iLN14C_form__cexp_tN14C_form__cexp_t(&v_565);
               if (v_564) {
                  _fx_free_LN14C_form__cexp_t(&v_564);
               }
               if (v_563) {
                  _fx_free_LN14C_form__cexp_t(&v_563);
               }
               if (v_562) {
                  _fx_free_N14C_form__cexp_t(&v_562);
               }
               if (elem_ptr_0) {
                  _fx_free_N14C_form__cexp_t(&elem_ptr_0);
               }
               _fx_free_T2iN14C_form__cexp_t(&v_561);
               if (v_560) {
                  _fx_free_N14K_form__ktyp_t(&v_560);
               }
               if (elem_ktyp_0) {
                  _fx_free_N14K_form__ktyp_t(&elem_ktyp_0);
               }
               _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_559);
               if (ccode_107) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_107);
               }
               if (e_10) {
                  _fx_free_N14C_form__cexp_t(&e_10);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_558);
               if (ccode_106) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_106);
               }
               if (arr_data_3) {
                  _fx_free_LN14C_form__cexp_t(&arr_data_3);
               }
               if (tags_data_4) {
                  _fx_free_LN14C_form__cexp_t(&tags_data_4);
               }
               if (scalars_data_3) {
                  _fx_free_LN14C_form__cexp_t(&scalars_data_3);
               }
               _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_557);
               _fx_free_N14K_form__atom_t(&a_4);
               FX_CHECK_EXN(_fx_catch_118);
            }
            _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___11, &v_553);
            int_ nscalars_2 = v_553.t0;
            FX_COPY_PTR(v_553.t1, &scalars_data_2);
            FX_COPY_PTR(v_553.t2, &tags_data_3);
            FX_COPY_PTR(v_553.t3, &arr_data_2);
            FX_COPY_PTR(v_553.t4, &ccode_105);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(127, &kloc_0, &v_554, 0), _fx_catch_118);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_554, tags_data_3, true, &v_555), _fx_catch_118);
            _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(nscalars_2, scalars_data_2,
               v_555, arr_data_2, ccode_105, &v_556);
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___7);
            _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_556, &__fold_result___7);

         _fx_catch_118: ;
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_556);
            if (v_555) {
               _fx_free_LN14C_form__cexp_t(&v_555);
            }
            if (v_554) {
               _fx_free_N14C_form__cexp_t(&v_554);
            }
            if (ccode_105) {
               _fx_free_LN15C_form__cstmt_t(&ccode_105);
            }
            if (arr_data_2) {
               _fx_free_LN14C_form__cexp_t(&arr_data_2);
            }
            if (tags_data_3) {
               _fx_free_LN14C_form__cexp_t(&tags_data_3);
            }
            if (scalars_data_2) {
               _fx_free_LN14C_form__cexp_t(&scalars_data_2);
            }
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_553);
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___11);
            if (ccode_104) {
               _fx_free_LN15C_form__cstmt_t(&ccode_104);
            }
            if (arr_data_1) {
               _fx_free_LN14C_form__cexp_t(&arr_data_1);
            }
            if (tags_data_2) {
               _fx_free_LN14C_form__cexp_t(&tags_data_2);
            }
            if (scalars_data_1) {
               _fx_free_LN14C_form__cexp_t(&scalars_data_1);
            }
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_552);
            FX_CHECK_EXN(_fx_catch_126);
         }
         _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___7, &v_511);
         FX_COPY_PTR(v_511.t1, &scalars_data_0);
         FX_COPY_PTR(v_511.t2, &tags_data_0);
         FX_COPY_PTR(v_511.t3, &arr_data_0);
         FX_COPY_PTR(v_511.t4, &ccode_99);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(scalars_data_0, &v_512, 0), _fx_catch_126);
         FX_CALL(
            _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &scalars_id_0, elem_ctyp_1, v_512, 0, &kloc_0, &v_513, 0), _fx_catch_126);
         FX_COPY_PTR(v_513.t1, &sub_ccode_2);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(-1, &kloc_0, &v_514, 0), _fx_catch_126);
         FX_CALL(_fx_M10C_gen_codeFM2tlLN14C_form__cexp_t1LN14C_form__cexp_t(tags_data_0, &v_515, 0), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_514, v_515, true, &v_516), _fx_catch_126);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(v_516, &tags_data_1, 0), _fx_catch_126);
         _fx_R9Ast__id_t v_580;
         fx_str_t slit_132 = FX_MAKE_STR("tags");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_132, &v_580, 0), _fx_catch_126);
         FX_CALL(_fx_M6C_formFM8CTypSIntN14C_form__ctyp_t1i(8, &v_517), _fx_catch_126);
         FX_CALL(
            _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_580, v_517, tags_data_1, sub_ccode_2, &kloc_0, &v_518, 0), _fx_catch_126);
         FX_COPY_PTR(v_518.t0, &tags_exp_0);
         FX_COPY_PTR(v_518.t1, &sub_ccode_3);
         _fx_R9Ast__id_t v_581;
         fx_str_t slit_133 = FX_MAKE_STR("parts");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_133, &v_581, 0), _fx_catch_126);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(arr_data_0, &v_519, 0), _fx_catch_126);
         FX_CALL(
            _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_581, _fx_g23C_form__std_CTypVoidPtr, v_519, sub_ccode_3, &kloc_0, &v_520, 0), _fx_catch_126);
         FX_COPY_PTR(v_520.t0, &arr_data_exp_0);
         FX_COPY_PTR(v_520.t1, &sub_ccode_4);
         FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_1, &kloc_0, &v_521),
            _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_521, 0, true, &v_522), _fx_catch_126);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g18C_form__std_sizeof, v_522, _fx_g22C_gen_code__CTypSize_t, &kloc_0, &sizeof_elem_exp_0, 0),
            _fx_catch_126);
         FX_CALL(
            _fx_M11C_gen_typesFM10get_free_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(elem_ctyp_1, true,
               false, &kloc_0, &v_523, 0), _fx_catch_126);
         _fx_Nt6option1N14C_form__cexp_t* v_582 = &v_523.t1;
         if (v_582->tag == 2) {
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_582->u.Some,
                  _fx_g21C_form__std_fx_free_t, &kloc_0, &free_f_exp_0), _fx_catch_119);

         _fx_catch_119: ;
         }
         else {
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &free_f_exp_0, 0), _fx_catch_120);

         _fx_catch_120: ;
         }
         FX_CHECK_EXN(_fx_catch_126);
         FX_CALL(
            _fx_M11C_gen_typesFM10get_copy_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(elem_ctyp_1, true,
               false, &kloc_0, &v_524, 0), _fx_catch_126);
         _fx_Nt6option1N14C_form__cexp_t* v_583 = &v_524.t1;
         if (v_583->tag == 2) {
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_583->u.Some,
                  _fx_g21C_form__std_fx_copy_t, &kloc_0, &copy_f_exp_0), _fx_catch_121);

         _fx_catch_121: ;
         }
         else {
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &copy_f_exp_0, 0), _fx_catch_122);

         _fx_catch_122: ;
         }
         FX_CHECK_EXN(_fx_catch_126);
         _fx_R9Ast__id_t v_584;
         fx_str_t slit_134 = FX_MAKE_STR("fx_compose_arr");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_134, &v_584, 0), _fx_catch_126);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(dims_0, &kloc_0, &v_525, 0), _fx_catch_126);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_3, &v_526, 0), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_526, 0, true, &v_527), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_data_exp_0, v_527, false, &v_527), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(tags_exp_0, v_527, false, &v_527), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_0, v_527, false, &v_527), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_0, v_527, false, &v_527), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(sizeof_elem_exp_0, v_527, false, &v_527), _fx_catch_126);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_525, v_527, false, &v_527), _fx_catch_126);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_584, v_527,
               _fx_g20C_gen_code__CTypCInt, &kloc_0, &call_mkarr_0, 0), _fx_catch_126);
         FX_CALL(
            _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               call_mkarr_0, sub_ccode_4, &kloc_0, block_stack_ref_0, &sub_ccode_5, 0), _fx_catch_126);
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(sub_ccode_5, &kloc_0, &v_528, 0),
            _fx_catch_126);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_528, ccode_99, true, &ccode_100), _fx_catch_126);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, arr_exp_3, ccode_100, &v_1);
      }
      else {
         fx_str_t slit_135 = FX_MAKE_STR("arr");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_135, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_529, 0), _fx_catch_126);
         FX_COPY_PTR(v_529.t0, &arr_exp_4);
         FX_COPY_PTR(v_529.t1, &ccode_101);
         int_ nrows_0;
         FX_CALL(_fx_M10C_gen_codeFM8length1_i1LLT2BN14K_form__atom_t(arows_3, &nrows_0, 0), _fx_catch_126);
         FX_CALL(_fx_M10C_gen_codeFM2hdLT2BN14K_form__atom_t1LLT2BN14K_form__atom_t(arows_3, &v_530, 0), _fx_catch_126);
         int_ ncols_0;
         FX_CALL(_fx_M10C_gen_codeFM8length1_i1LT2BN14K_form__atom_t(v_530, &ncols_0, 0), _fx_catch_126);
         if (nrows_0 > 1) {
            FX_CALL(_fx_cons_Li(ncols_0, 0, true, &v_531), _fx_catch_126);
            FX_CALL(_fx_cons_Li(nrows_0, v_531, true, &shape_0), _fx_catch_126);
         }
         else {
            FX_CALL(_fx_cons_Li(ncols_0, 0, true, &shape_0), _fx_catch_126);
         }
         _fx_LN14C_form__cexp_t lstend_0 = 0;
         _fx_Li lst_13 = shape_0;
         for (; lst_13; lst_13 = lst_13->tl) {
            _fx_N14C_form__cexp_t res_17 = 0;
            int_ i_5 = lst_13->hd;
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(i_5, &kloc_0, &res_17, 0), _fx_catch_123);
            _fx_LN14C_form__cexp_t node_0 = 0;
            FX_CALL(_fx_cons_LN14C_form__cexp_t(res_17, 0, false, &node_0), _fx_catch_123);
            FX_LIST_APPEND(shape_1, lstend_0, node_0);

         _fx_catch_123: ;
            if (res_17) {
               _fx_free_N14C_form__cexp_t(&res_17);
            }
            FX_CHECK_EXN(_fx_catch_126);
         }
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_101, &__fold_result___8);
         FX_COPY_PTR(arows_3, &arows_2);
         _fx_LLT2BN14K_form__atom_t lst_14 = arows_2;
         for (; lst_14; lst_14 = lst_14->tl) {
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_585 = {0};
            _fx_LN14C_form__cexp_t data_1 = 0;
            _fx_LN15C_form__cstmt_t ccode_108 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___12 = {0};
            _fx_LT2BN14K_form__atom_t arow_2 = lst_14->hd;
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___8, &v_585);
            FX_COPY_PTR(v_585.t0, &data_1);
            FX_COPY_PTR(v_585.t1, &ccode_108);
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(data_1, ccode_108, &__fold_result___12);
            _fx_LT2BN14K_form__atom_t lst_15 = arow_2;
            for (; lst_15; lst_15 = lst_15->tl) {
               _fx_N14K_form__atom_t a_5 = {0};
               _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_586 = {0};
               _fx_LN14C_form__cexp_t data_2 = 0;
               _fx_LN15C_form__cstmt_t ccode_109 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_587 = {0};
               _fx_N14C_form__cexp_t e_11 = 0;
               _fx_LN15C_form__cstmt_t ccode_110 = 0;
               _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_588 = {0};
               _fx_T2BN14K_form__atom_t* __pat___2 = &lst_15->hd;
               _fx_copy_N14K_form__atom_t(&__pat___2->t1, &a_5);
               _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___12, &v_586);
               FX_COPY_PTR(v_586.t0, &data_2);
               FX_COPY_PTR(v_586.t1, &ccode_109);
               FX_CALL(
                  atom2cexp_0.fp(&a_5, ccode_109, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                     km_idx_0, &v_587, atom2cexp_0.fcv), _fx_catch_124);
               FX_COPY_PTR(v_587.t0, &e_11);
               FX_COPY_PTR(v_587.t1, &ccode_110);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(e_11, data_2, false, &data_2), _fx_catch_124);
               _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(data_2, ccode_110, &v_588);
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___12);
               _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_588, &__fold_result___12);

            _fx_catch_124: ;
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_588);
               if (ccode_110) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_110);
               }
               if (e_11) {
                  _fx_free_N14C_form__cexp_t(&e_11);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_587);
               if (ccode_109) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_109);
               }
               if (data_2) {
                  _fx_free_LN14C_form__cexp_t(&data_2);
               }
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_586);
               _fx_free_N14K_form__atom_t(&a_5);
               FX_CHECK_EXN(_fx_catch_125);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___8);
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___12, &__fold_result___8);

         _fx_catch_125: ;
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___12);
            if (ccode_108) {
               _fx_free_LN15C_form__cstmt_t(&ccode_108);
            }
            if (data_1) {
               _fx_free_LN14C_form__cexp_t(&data_1);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_585);
            FX_CHECK_EXN(_fx_catch_126);
         }
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___8, &v_532);
         FX_COPY_PTR(v_532.t0, &data_0);
         FX_COPY_PTR(v_532.t1, &ccode_102);
         if (all_literals_0) {
            int_ dims_1;
            FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(shape_1, &dims_1, 0), _fx_catch_126);
            FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_533), _fx_catch_126);
            FX_CALL(
               _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_533,
                  _fx_g19C_gen_code__CTypInt, &shape_ctyp_0), _fx_catch_126);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(shape_ctyp_0, &kloc_0, &v_534);
            FX_CALL(
               _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(shape_1, &v_534,
                  &shape_arr_0), _fx_catch_126);
            _fx_R9Ast__id_t v_589;
            fx_str_t slit_136 = FX_MAKE_STR("shape");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_136, &v_589, 0), _fx_catch_126);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_535, 0), _fx_catch_126);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(shape_arr_0, &v_536);
            fx_str_t slit_137 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_589, shape_ctyp_0, &v_535, &slit_137, &v_536, 0, &kloc_0, &v_537, 0), _fx_catch_126);
            FX_COPY_PTR(v_537.t0, &shape_exp_0);
            FX_COPY_PTR(v_537.t1, &ccode__0);
            _fx_R9Ast__id_t data_id_0;
            fx_str_t slit_138 = FX_MAKE_STR("data");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_138, &data_id_0, 0), _fx_catch_126);
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(data_0, &v_538, 0), _fx_catch_126);
            FX_CALL(
               _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &data_id_0, elem_ctyp_1, v_538, *glob_data_ccode_0, &kloc_0, &v_539, 0), _fx_catch_126);
            FX_COPY_PTR(v_539.t0, &data_exp_0);
            FX_COPY_PTR(v_539.t1, &glob_data_ccode__0);
            FX_CALL(_fx_M6C_formFM8get_cvalRM9cdefval_t2R9Ast__id_tR10Ast__loc_t(&data_id_0, &kloc_0, &data_cv_0, 0),
               _fx_catch_126);
            _fx_copy_R16Ast__val_flags_t(&data_cv_0.cv_flags, &data_flags_0);
            _fx_make_R16Ast__val_flags_t(data_flags_0.val_flag_arg, data_flags_0.val_flag_mutable, data_flags_0.val_flag_temp,
               data_flags_0.val_flag_tempref, true, data_flags_0.val_flag_subarray, data_flags_0.val_flag_instance,
               &data_flags_0.val_flag_method, data_flags_0.val_flag_ctor, data_flags_0.val_flag_global, &v_540);
            _fx_make_R17C_form__cdefval_t(&data_cv_0.cv_name, data_cv_0.cv_typ, &data_cv_0.cv_cname, &v_540, &data_cv_0.cv_loc,
               &v_541);
            _fx_M6C_formFM4CValN15C_form__cinfo_t1RM9cdefval_t(&v_541, &v_542);
            FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(&data_id_0, &v_542, 0), _fx_catch_126);
            _fx_free_LN15C_form__cstmt_t(glob_data_ccode_0);
            FX_COPY_PTR(glob_data_ccode__0, glob_data_ccode_0);
            FX_CALL(
               _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_1,
                  &kloc_0, &v_543, 0), _fx_catch_126);
            FX_COPY_PTR(v_543.t0, &sizeof_elem_exp_1);
            FX_COPY_PTR(v_543.t1, &free_f_exp_1);
            FX_COPY_PTR(v_543.t2, &copy_f_exp_1);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(dims_1, &kloc_0, &v_544, 0), _fx_catch_126);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_4, &v_545, 0), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_545, 0, true, &v_546), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(data_exp_0, v_546, false, &v_546), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_1, v_546, false, &v_546), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_1, v_546, false, &v_546), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(sizeof_elem_exp_1, v_546, false, &v_546), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(shape_exp_0, v_546, false, &v_546), _fx_catch_126);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_544, v_546, false, &v_546), _fx_catch_126);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g23C_form__std_fx_make_arr, v_546, _fx_g20C_gen_code__CTypCInt, &kloc_0, &call_mkarr_1, 0),
               _fx_catch_126);
            FX_CALL(
               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  call_mkarr_1, ccode__0, &kloc_0, block_stack_ref_0, &ccode__1, 0), _fx_catch_126);
            FX_CALL(
               _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(ccode__1, &kloc_0, &v_547, 0),
               _fx_catch_126);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_547, ccode_102, true, &v_548), _fx_catch_126);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, arr_exp_4, v_548, &v_1);
         }
         else {
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(data_0, &v_549, 0), _fx_catch_126);
            FX_CALL(
               _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0,
                  block_stack_ref_0, &v_550, 0), _fx_catch_126);
            FX_CALL(
               _fx_M10C_gen_codeFM18make_make_arr_callLN15C_form__cstmt_t7N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
                  arr_exp_4, shape_1, v_549, ccode_102, v_550, &kloc_0, km_idx_0, &ccode_103, 0), _fx_catch_126);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, arr_exp_4, ccode_103, &v_1);
         }
      }

   _fx_catch_126: ;
      if (ccode_103) {
         _fx_free_LN15C_form__cstmt_t(&ccode_103);
      }
      if (v_550) {
         _fx_free_N14C_form__cexp_t(&v_550);
      }
      if (v_549) {
         _fx_free_LN14C_form__cexp_t(&v_549);
      }
      if (v_548) {
         _fx_free_LN15C_form__cstmt_t(&v_548);
      }
      if (v_547) {
         _fx_free_N15C_form__cstmt_t(&v_547);
      }
      if (ccode__1) {
         _fx_free_LN15C_form__cstmt_t(&ccode__1);
      }
      if (call_mkarr_1) {
         _fx_free_N14C_form__cexp_t(&call_mkarr_1);
      }
      if (v_546) {
         _fx_free_LN14C_form__cexp_t(&v_546);
      }
      if (v_545) {
         _fx_free_N14C_form__cexp_t(&v_545);
      }
      if (v_544) {
         _fx_free_N14C_form__cexp_t(&v_544);
      }
      if (copy_f_exp_1) {
         _fx_free_N14C_form__cexp_t(&copy_f_exp_1);
      }
      if (free_f_exp_1) {
         _fx_free_N14C_form__cexp_t(&free_f_exp_1);
      }
      if (sizeof_elem_exp_1) {
         _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_1);
      }
      _fx_free_Ta3N14C_form__cexp_t(&v_543);
      _fx_free_N15C_form__cinfo_t(&v_542);
      _fx_free_R17C_form__cdefval_t(&v_541);
      _fx_free_R16Ast__val_flags_t(&v_540);
      _fx_free_R16Ast__val_flags_t(&data_flags_0);
      _fx_free_R17C_form__cdefval_t(&data_cv_0);
      if (glob_data_ccode__0) {
         _fx_free_LN15C_form__cstmt_t(&glob_data_ccode__0);
      }
      if (data_exp_0) {
         _fx_free_N14C_form__cexp_t(&data_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_539);
      if (v_538) {
         _fx_free_LN14C_form__cexp_t(&v_538);
      }
      if (ccode__0) {
         _fx_free_LN15C_form__cstmt_t(&ccode__0);
      }
      if (shape_exp_0) {
         _fx_free_N14C_form__cexp_t(&shape_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_537);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_536);
      _fx_free_R16Ast__val_flags_t(&v_535);
      if (shape_arr_0) {
         _fx_free_N14C_form__cexp_t(&shape_arr_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_534);
      if (shape_ctyp_0) {
         _fx_free_N14C_form__ctyp_t(&shape_ctyp_0);
      }
      FX_FREE_LIST_SIMPLE(&v_533);
      if (ccode_102) {
         _fx_free_LN15C_form__cstmt_t(&ccode_102);
      }
      if (data_0) {
         _fx_free_LN14C_form__cexp_t(&data_0);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_532);
      if (arows_2) {
         _fx_free_LLT2BN14K_form__atom_t(&arows_2);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___8);
      if (shape_1) {
         _fx_free_LN14C_form__cexp_t(&shape_1);
      }
      FX_FREE_LIST_SIMPLE(&v_531);
      FX_FREE_LIST_SIMPLE(&shape_0);
      if (v_530) {
         _fx_free_LT2BN14K_form__atom_t(&v_530);
      }
      if (ccode_101) {
         _fx_free_LN15C_form__cstmt_t(&ccode_101);
      }
      if (arr_exp_4) {
         _fx_free_N14C_form__cexp_t(&arr_exp_4);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_529);
      if (ccode_100) {
         _fx_free_LN15C_form__cstmt_t(&ccode_100);
      }
      if (v_528) {
         _fx_free_N15C_form__cstmt_t(&v_528);
      }
      if (sub_ccode_5) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_5);
      }
      if (call_mkarr_0) {
         _fx_free_N14C_form__cexp_t(&call_mkarr_0);
      }
      if (v_527) {
         _fx_free_LN14C_form__cexp_t(&v_527);
      }
      if (v_526) {
         _fx_free_N14C_form__cexp_t(&v_526);
      }
      if (v_525) {
         _fx_free_N14C_form__cexp_t(&v_525);
      }
      if (copy_f_exp_0) {
         _fx_free_N14C_form__cexp_t(&copy_f_exp_0);
      }
      _fx_free_T2BNt6option1N14C_form__cexp_t(&v_524);
      if (free_f_exp_0) {
         _fx_free_N14C_form__cexp_t(&free_f_exp_0);
      }
      _fx_free_T2BNt6option1N14C_form__cexp_t(&v_523);
      if (sizeof_elem_exp_0) {
         _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_0);
      }
      if (v_522) {
         _fx_free_LN14C_form__cexp_t(&v_522);
      }
      if (v_521) {
         _fx_free_N14C_form__cexp_t(&v_521);
      }
      if (sub_ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_4);
      }
      if (arr_data_exp_0) {
         _fx_free_N14C_form__cexp_t(&arr_data_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_520);
      if (v_519) {
         _fx_free_LN14C_form__cexp_t(&v_519);
      }
      if (sub_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_3);
      }
      if (tags_exp_0) {
         _fx_free_N14C_form__cexp_t(&tags_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_518);
      if (v_517) {
         _fx_free_N14C_form__ctyp_t(&v_517);
      }
      if (tags_data_1) {
         _fx_free_LN14C_form__cexp_t(&tags_data_1);
      }
      if (v_516) {
         _fx_free_LN14C_form__cexp_t(&v_516);
      }
      if (v_515) {
         _fx_free_LN14C_form__cexp_t(&v_515);
      }
      if (v_514) {
         _fx_free_N14C_form__cexp_t(&v_514);
      }
      if (sub_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_2);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_513);
      if (v_512) {
         _fx_free_LN14C_form__cexp_t(&v_512);
      }
      if (ccode_99) {
         _fx_free_LN15C_form__cstmt_t(&ccode_99);
      }
      if (arr_data_0) {
         _fx_free_LN14C_form__cexp_t(&arr_data_0);
      }
      if (tags_data_0) {
         _fx_free_LN14C_form__cexp_t(&tags_data_0);
      }
      if (scalars_data_0) {
         _fx_free_LN14C_form__cexp_t(&scalars_data_0);
      }
      _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_511);
      if (arows_1) {
         _fx_free_LLT2BN14K_form__atom_t(&arows_1);
      }
      _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___7);
      if (scalars_exp_0) {
         _fx_free_N14C_form__cexp_t(&scalars_exp_0);
      }
      if (v_510) {
         _fx_free_N14C_form__ctyp_t(&v_510);
      }
      if (ccode_98) {
         _fx_free_LN15C_form__cstmt_t(&ccode_98);
      }
      if (arr_exp_3) {
         _fx_free_N14C_form__cexp_t(&arr_exp_3);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_509);
      if (elem_ctyp_1) {
         _fx_free_N14C_form__ctyp_t(&elem_ctyp_1);
      }
      _fx_free_T2iN14C_form__ctyp_t(&v_508);
      if (arows_0) {
         _fx_free_LLT2BN14K_form__atom_t(&arows_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 18) {
      _fx_LT2BN14K_form__atom_t elems_0 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_590 = {0};
      _fx_N14C_form__cexp_t vec_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_111 = 0;
      _fx_N14C_form__ctyp_t elem_ctyp_2 = 0;
      _fx_N14C_form__ctyp_t v_591 = 0;
      _fx_N14C_form__cexp_t scalars_exp_1 = 0;
      _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___13 = {0};
      _fx_LT2BN14K_form__atom_t elems_1 = 0;
      _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_592 = {0};
      _fx_LN14C_form__cexp_t scalars_data_5 = 0;
      _fx_LN14C_form__cexp_t tags_data_5 = 0;
      _fx_LN14C_form__cexp_t vec_data_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_112 = 0;
      _fx_LN14C_form__cexp_t v_593 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_594 = {0};
      _fx_LN15C_form__cstmt_t sub_ccode_6 = 0;
      _fx_N14C_form__cexp_t v_595 = 0;
      _fx_LN14C_form__cexp_t v_596 = 0;
      _fx_LN14C_form__cexp_t v_597 = 0;
      _fx_LN14C_form__cexp_t tags_data_6 = 0;
      _fx_N14C_form__ctyp_t v_598 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_599 = {0};
      _fx_N14C_form__cexp_t tags_exp_1 = 0;
      _fx_LN15C_form__cstmt_t sub_ccode_7 = 0;
      _fx_LN14C_form__cexp_t v_600 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_601 = {0};
      _fx_N14C_form__cexp_t vec_data_exp_0 = 0;
      _fx_LN15C_form__cstmt_t sub_ccode_8 = 0;
      _fx_N14C_form__cexp_t v_602 = 0;
      _fx_LN14C_form__cexp_t v_603 = 0;
      _fx_N14C_form__cexp_t sizeof_elem_exp_2 = 0;
      _fx_T2BNt6option1N14C_form__cexp_t v_604 = {0};
      _fx_N14C_form__cexp_t free_f_exp_2 = 0;
      _fx_T2BNt6option1N14C_form__cexp_t v_605 = {0};
      _fx_N14C_form__cexp_t copy_f_exp_2 = 0;
      _fx_N14C_form__cexp_t v_606 = 0;
      _fx_LN14C_form__cexp_t v_607 = 0;
      _fx_N14C_form__cexp_t call_mkvec_0 = 0;
      _fx_LN15C_form__cstmt_t sub_ccode_9 = 0;
      _fx_N15C_form__cstmt_t v_608 = 0;
      _fx_LN15C_form__cstmt_t ccode_113 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___14 = {0};
      _fx_LT2BN14K_form__atom_t elems_2 = 0;
      _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_609 = {0};
      _fx_LN14C_form__cexp_t data_3 = 0;
      _fx_LN15C_form__cstmt_t ccode_114 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_610 = {0};
      _fx_N14C_form__cexp_t vec_exp_1 = 0;
      _fx_LN15C_form__cstmt_t ccode_115 = 0;
      _fx_LN14C_form__cexp_t v_611 = 0;
      _fx_N14C_form__cexp_t v_612 = 0;
      _fx_LN15C_form__cstmt_t ccode_116 = 0;
      _fx_LT2BN14K_form__atom_t elems_3 = kexp_0->u.KExpMkVector.t0;
      bool __fold_result___15 = false;
      FX_COPY_PTR(elems_3, &elems_0);
      _fx_LT2BN14K_form__atom_t lst_16 = elems_0;
      for (; lst_16; lst_16 = lst_16->tl) {
         _fx_T2BN14K_form__atom_t* __pat___3 = &lst_16->hd;
         if (__pat___3->t0) {
            __fold_result___15 = true; FX_BREAK(_fx_catch_127);
         }

      _fx_catch_127: ;
         FX_CHECK_BREAK();
         FX_CHECK_EXN(_fx_catch_140);
      }
      bool have_expanded_1 = __fold_result___15;
      if (have_expanded_1) {
         fx_str_t slit_139 = FX_MAKE_STR("vec");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_139, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_590, 0), _fx_catch_140);
         FX_COPY_PTR(v_590.t0, &vec_exp_0);
         FX_COPY_PTR(v_590.t1, &ccode_111);
         if (FX_REC_VARIANT_TAG(ctyp_0) == 20) {
            FX_COPY_PTR(ctyp_0->u.CTypVector, &elem_ctyp_2);
         }
         else {
            fx_exn_t v_613 = {0};
            fx_str_t slit_140 = FX_MAKE_STR("cgen: invalid output type of vector construction expression");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_140, &v_613, 0), _fx_catch_128);
            FX_THROW(&v_613, false, _fx_catch_128);

         _fx_catch_128: ;
            fx_free_exn(&v_613);
         }
         FX_CHECK_EXN(_fx_catch_140);
         _fx_R9Ast__id_t scalars_id_1;
         fx_str_t slit_141 = FX_MAKE_STR("scalars");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_141, &scalars_id_1, 0), _fx_catch_140);
         FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elem_ctyp_2, &v_591, 0), _fx_catch_140);
         FX_CALL(
            _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&scalars_id_1, v_591,
               &kloc_0, &scalars_exp_1, 0), _fx_catch_140);
         _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(0, 0, 0, 0, ccode_111,
            &__fold_result___13);
         FX_COPY_PTR(elems_3, &elems_1);
         _fx_LT2BN14K_form__atom_t lst_17 = elems_1;
         for (; lst_17; lst_17 = lst_17->tl) {
            _fx_N14K_form__atom_t a_6 = {0};
            _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_614 = {0};
            _fx_LN14C_form__cexp_t scalars_data_6 = 0;
            _fx_LN14C_form__cexp_t tags_data_7 = 0;
            _fx_LN14C_form__cexp_t vec_data_1 = 0;
            _fx_LN15C_form__cstmt_t ccode_117 = 0;
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_615 = {0};
            _fx_N14C_form__cexp_t e_12 = 0;
            _fx_LN15C_form__cstmt_t ccode_118 = 0;
            _fx_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_616 = {0};
            _fx_N14K_form__ktyp_t elem_ktyp_1 = 0;
            _fx_N14K_form__ktyp_t v_617 = 0;
            _fx_T2iN14C_form__cexp_t v_618 = {0};
            _fx_N14C_form__cexp_t elem_ptr_1 = 0;
            _fx_N14C_form__cexp_t v_619 = 0;
            _fx_LN14C_form__cexp_t v_620 = 0;
            _fx_LN14C_form__cexp_t v_621 = 0;
            _fx_T3iLN14C_form__cexp_tN14C_form__cexp_t v_622 = {0};
            _fx_LN14C_form__cexp_t scalars_data_7 = 0;
            _fx_N14C_form__cexp_t vec_data_elem_0 = 0;
            _fx_N14C_form__cexp_t v_623 = 0;
            _fx_LN14C_form__cexp_t v_624 = 0;
            _fx_LN14C_form__cexp_t v_625 = 0;
            _fx_T2BN14K_form__atom_t* __pat___4 = &lst_17->hd;
            _fx_copy_N14K_form__atom_t(&__pat___4->t1, &a_6);
            _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___13, &v_614);
            int_ nscalars_3 = v_614.t0;
            FX_COPY_PTR(v_614.t1, &scalars_data_6);
            FX_COPY_PTR(v_614.t2, &tags_data_7);
            FX_COPY_PTR(v_614.t3, &vec_data_1);
            FX_COPY_PTR(v_614.t4, &ccode_117);
            FX_CALL(
               atom2cexp_0.fp(&a_6, ccode_117, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                  km_idx_0, &v_615, atom2cexp_0.fcv), _fx_catch_134);
            FX_COPY_PTR(v_615.t0, &e_12);
            FX_COPY_PTR(v_615.t1, &ccode_118);
            if (__pat___4->t0) {
               FX_CALL(
                  _fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(&a_6, &kloc_0, &elem_ktyp_1, 0),
                  _fx_catch_134);
               FX_CALL(
                  _fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(elem_ktyp_1, &kloc_0, &v_617, 0),
                  _fx_catch_134);
               int tag_16 = FX_REC_VARIANT_TAG(v_617);
               if (tag_16 == 17) {
                  _fx_N14C_form__cexp_t v_626 = 0;
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_12, &v_626, 0), _fx_catch_129);
                  _fx_make_T2iN14C_form__cexp_t(v_617->u.KTypArray.t0, v_626, &v_618);

               _fx_catch_129: ;
                  if (v_626) {
                     _fx_free_N14C_form__cexp_t(&v_626);
                  }
               }
               else if (tag_16 == 19) {
                  _fx_make_T2iN14C_form__cexp_t(100, e_12, &v_618);
               }
               else if (tag_16 == 18) {
                  _fx_N14C_form__cexp_t v_627 = 0;
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_12, &v_627, 0), _fx_catch_130);
                  _fx_make_T2iN14C_form__cexp_t(110, v_627, &v_618);

               _fx_catch_130: ;
                  if (v_627) {
                     _fx_free_N14C_form__cexp_t(&v_627);
                  }
               }
               else {
                  fx_str_t v_628 = {0};
                  fx_str_t v_629 = {0};
                  fx_str_t v_630 = {0};
                  fx_exn_t v_631 = {0};
                  FX_CALL(_fx_M6K_formFM8atom2strS1N14K_form__atom_t(&a_6, &v_628, 0), _fx_catch_131);
                  FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_628, &v_629, 0), _fx_catch_131);
                  fx_str_t slit_142 = FX_MAKE_STR("cgen: the expanded structure ");
                  fx_str_t slit_143 = FX_MAKE_STR(" is not an array, vector or list");
                  {
                     const fx_str_t strs_30[] = { slit_142, v_629, slit_143 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_30, 3, &v_630), _fx_catch_131);
                  }
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_630, &v_631, 0), _fx_catch_131);
                  FX_THROW(&v_631, false, _fx_catch_131);

               _fx_catch_131: ;
                  fx_free_exn(&v_631);
                  FX_FREE_STR(&v_630);
                  FX_FREE_STR(&v_629);
                  FX_FREE_STR(&v_628);
               }
               FX_CHECK_EXN(_fx_catch_134);
               int_ tag_17 = v_618.t0;
               FX_COPY_PTR(v_618.t1, &elem_ptr_1);
               FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(tag_17, &kloc_0, &v_619, 0), _fx_catch_134);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_619, tags_data_7, true, &v_620), _fx_catch_134);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(elem_ptr_1, vec_data_1, true, &v_621), _fx_catch_134);
               _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(nscalars_3, scalars_data_6,
                  v_620, v_621, ccode_118, &v_616);
            }
            else {
               if (FX_REC_VARIANT_TAG(e_12) == 1) {
                  _fx_N14C_form__cexp_t v_632 = 0;
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_12, &v_632, 0), _fx_catch_132);
                  _fx_make_T3iLN14C_form__cexp_tN14C_form__cexp_t(nscalars_3, scalars_data_6, v_632, &v_622);

               _fx_catch_132: ;
                  if (v_632) {
                     _fx_free_N14C_form__cexp_t(&v_632);
                  }
               }
               else {
                  _fx_LN14C_form__cexp_t v_633 = 0;
                  _fx_N14C_form__cexp_t v_634 = 0;
                  _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_635 = {0};
                  _fx_N14C_form__cexp_t v_636 = 0;
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(e_12, scalars_data_6, true, &v_633), _fx_catch_133);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(nscalars_3, &kloc_0, &v_634, 0),
                     _fx_catch_133);
                  _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g23C_form__std_CTypVoidPtr, &kloc_0, &v_635);
                  FX_CALL(
                     _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g18C_gen_code__COpAdd, scalars_exp_1, v_634, &v_635, &v_636), _fx_catch_133);
                  _fx_make_T3iLN14C_form__cexp_tN14C_form__cexp_t(nscalars_3 + 1, v_633, v_636, &v_622);

               _fx_catch_133: ;
                  if (v_636) {
                     _fx_free_N14C_form__cexp_t(&v_636);
                  }
                  _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_635);
                  if (v_634) {
                     _fx_free_N14C_form__cexp_t(&v_634);
                  }
                  if (v_633) {
                     _fx_free_LN14C_form__cexp_t(&v_633);
                  }
               }
               FX_CHECK_EXN(_fx_catch_134);
               int_ nscalars_4 = v_622.t0;
               FX_COPY_PTR(v_622.t1, &scalars_data_7);
               FX_COPY_PTR(v_622.t2, &vec_data_elem_0);
               FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_623, 0), _fx_catch_134);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(v_623, tags_data_7, true, &v_624), _fx_catch_134);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(vec_data_elem_0, vec_data_1, true, &v_625), _fx_catch_134);
               _fx_make_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(nscalars_4, scalars_data_7,
                  v_624, v_625, ccode_118, &v_616);
            }
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___13);
            _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_616, &__fold_result___13);

         _fx_catch_134: ;
            if (v_625) {
               _fx_free_LN14C_form__cexp_t(&v_625);
            }
            if (v_624) {
               _fx_free_LN14C_form__cexp_t(&v_624);
            }
            if (v_623) {
               _fx_free_N14C_form__cexp_t(&v_623);
            }
            if (vec_data_elem_0) {
               _fx_free_N14C_form__cexp_t(&vec_data_elem_0);
            }
            if (scalars_data_7) {
               _fx_free_LN14C_form__cexp_t(&scalars_data_7);
            }
            _fx_free_T3iLN14C_form__cexp_tN14C_form__cexp_t(&v_622);
            if (v_621) {
               _fx_free_LN14C_form__cexp_t(&v_621);
            }
            if (v_620) {
               _fx_free_LN14C_form__cexp_t(&v_620);
            }
            if (v_619) {
               _fx_free_N14C_form__cexp_t(&v_619);
            }
            if (elem_ptr_1) {
               _fx_free_N14C_form__cexp_t(&elem_ptr_1);
            }
            _fx_free_T2iN14C_form__cexp_t(&v_618);
            if (v_617) {
               _fx_free_N14K_form__ktyp_t(&v_617);
            }
            if (elem_ktyp_1) {
               _fx_free_N14K_form__ktyp_t(&elem_ktyp_1);
            }
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_616);
            if (ccode_118) {
               _fx_free_LN15C_form__cstmt_t(&ccode_118);
            }
            if (e_12) {
               _fx_free_N14C_form__cexp_t(&e_12);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_615);
            if (ccode_117) {
               _fx_free_LN15C_form__cstmt_t(&ccode_117);
            }
            if (vec_data_1) {
               _fx_free_LN14C_form__cexp_t(&vec_data_1);
            }
            if (tags_data_7) {
               _fx_free_LN14C_form__cexp_t(&tags_data_7);
            }
            if (scalars_data_6) {
               _fx_free_LN14C_form__cexp_t(&scalars_data_6);
            }
            _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_614);
            _fx_free_N14K_form__atom_t(&a_6);
            FX_CHECK_EXN(_fx_catch_140);
         }
         _fx_copy_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___13, &v_592);
         FX_COPY_PTR(v_592.t1, &scalars_data_5);
         FX_COPY_PTR(v_592.t2, &tags_data_5);
         FX_COPY_PTR(v_592.t3, &vec_data_0);
         FX_COPY_PTR(v_592.t4, &ccode_112);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(scalars_data_5, &v_593, 0), _fx_catch_140);
         FX_CALL(
            _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &scalars_id_1, elem_ctyp_2, v_593, 0, &kloc_0, &v_594, 0), _fx_catch_140);
         FX_COPY_PTR(v_594.t1, &sub_ccode_6);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(-1, &kloc_0, &v_595, 0), _fx_catch_140);
         FX_CALL(_fx_M10C_gen_codeFM2tlLN14C_form__cexp_t1LN14C_form__cexp_t(tags_data_5, &v_596, 0), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_595, v_596, true, &v_597), _fx_catch_140);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(v_597, &tags_data_6, 0), _fx_catch_140);
         _fx_R9Ast__id_t v_637;
         fx_str_t slit_144 = FX_MAKE_STR("tags");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_144, &v_637, 0), _fx_catch_140);
         FX_CALL(_fx_M6C_formFM8CTypSIntN14C_form__ctyp_t1i(8, &v_598), _fx_catch_140);
         FX_CALL(
            _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_637, v_598, tags_data_6, sub_ccode_6, &kloc_0, &v_599, 0), _fx_catch_140);
         FX_COPY_PTR(v_599.t0, &tags_exp_1);
         FX_COPY_PTR(v_599.t1, &sub_ccode_7);
         _fx_R9Ast__id_t v_638;
         fx_str_t slit_145 = FX_MAKE_STR("parts");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_145, &v_638, 0), _fx_catch_140);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(vec_data_0, &v_600, 0), _fx_catch_140);
         FX_CALL(
            _fx_M10C_gen_codeFM14decl_plain_arrT2N14C_form__cexp_tLN15C_form__cstmt_t5R9Ast__id_tN14C_form__ctyp_tLN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_638, _fx_g23C_form__std_CTypVoidPtr, v_600, sub_ccode_7, &kloc_0, &v_601, 0), _fx_catch_140);
         FX_COPY_PTR(v_601.t0, &vec_data_exp_0);
         FX_COPY_PTR(v_601.t1, &sub_ccode_8);
         FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elem_ctyp_2, &kloc_0, &v_602),
            _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_602, 0, true, &v_603), _fx_catch_140);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g18C_form__std_sizeof, v_603, _fx_g22C_gen_code__CTypSize_t, &kloc_0, &sizeof_elem_exp_2, 0),
            _fx_catch_140);
         FX_CALL(
            _fx_M11C_gen_typesFM10get_free_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(elem_ctyp_2, true,
               false, &kloc_0, &v_604, 0), _fx_catch_140);
         _fx_Nt6option1N14C_form__cexp_t* v_639 = &v_604.t1;
         if (v_639->tag == 2) {
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_639->u.Some,
                  _fx_g21C_form__std_fx_free_t, &kloc_0, &free_f_exp_2), _fx_catch_135);

         _fx_catch_135: ;
         }
         else {
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &free_f_exp_2, 0), _fx_catch_136);

         _fx_catch_136: ;
         }
         FX_CHECK_EXN(_fx_catch_140);
         FX_CALL(
            _fx_M11C_gen_typesFM10get_copy_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(elem_ctyp_2, true,
               false, &kloc_0, &v_605, 0), _fx_catch_140);
         _fx_Nt6option1N14C_form__cexp_t* v_640 = &v_605.t1;
         if (v_640->tag == 2) {
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_640->u.Some,
                  _fx_g21C_form__std_fx_copy_t, &kloc_0, &copy_f_exp_2), _fx_catch_137);

         _fx_catch_137: ;
         }
         else {
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &copy_f_exp_2, 0), _fx_catch_138);

         _fx_catch_138: ;
         }
         FX_CHECK_EXN(_fx_catch_140);
         _fx_R9Ast__id_t v_641;
         fx_str_t slit_146 = FX_MAKE_STR("fx_compose_vec");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_146, &v_641, 0), _fx_catch_140);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(vec_exp_0, &v_606, 0), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_606, 0, true, &v_607), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(vec_data_exp_0, v_607, false, &v_607), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(tags_exp_1, v_607, false, &v_607), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_2, v_607, false, &v_607), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_2, v_607, false, &v_607), _fx_catch_140);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(sizeof_elem_exp_2, v_607, false, &v_607), _fx_catch_140);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_641, v_607,
               _fx_g20C_gen_code__CTypCInt, &kloc_0, &call_mkvec_0, 0), _fx_catch_140);
         FX_CALL(
            _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
               call_mkvec_0, sub_ccode_8, &kloc_0, block_stack_ref_0, &sub_ccode_9, 0), _fx_catch_140);
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(sub_ccode_9, &kloc_0, &v_608, 0),
            _fx_catch_140);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_608, ccode_112, true, &ccode_113), _fx_catch_140);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, vec_exp_0, ccode_113, &v_1);
      }
      else {
         _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_0, &__fold_result___14);
         FX_COPY_PTR(elems_3, &elems_2);
         _fx_LT2BN14K_form__atom_t lst_18 = elems_2;
         for (; lst_18; lst_18 = lst_18->tl) {
            _fx_N14K_form__atom_t a_7 = {0};
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_642 = {0};
            _fx_LN14C_form__cexp_t data_4 = 0;
            _fx_LN15C_form__cstmt_t ccode_119 = 0;
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_643 = {0};
            _fx_N14C_form__cexp_t e_13 = 0;
            _fx_LN15C_form__cstmt_t ccode_120 = 0;
            _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_644 = {0};
            _fx_T2BN14K_form__atom_t* __pat___5 = &lst_18->hd;
            _fx_copy_N14K_form__atom_t(&__pat___5->t1, &a_7);
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___14, &v_642);
            FX_COPY_PTR(v_642.t0, &data_4);
            FX_COPY_PTR(v_642.t1, &ccode_119);
            FX_CALL(
               atom2cexp_0.fp(&a_7, ccode_119, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                  km_idx_0, &v_643, atom2cexp_0.fcv), _fx_catch_139);
            FX_COPY_PTR(v_643.t0, &e_13);
            FX_COPY_PTR(v_643.t1, &ccode_120);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(e_13, data_4, false, &data_4), _fx_catch_139);
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(data_4, ccode_120, &v_644);
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___14);
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_644, &__fold_result___14);

         _fx_catch_139: ;
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_644);
            if (ccode_120) {
               _fx_free_LN15C_form__cstmt_t(&ccode_120);
            }
            if (e_13) {
               _fx_free_N14C_form__cexp_t(&e_13);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_643);
            if (ccode_119) {
               _fx_free_LN15C_form__cstmt_t(&ccode_119);
            }
            if (data_4) {
               _fx_free_LN14C_form__cexp_t(&data_4);
            }
            _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_642);
            _fx_free_N14K_form__atom_t(&a_7);
            FX_CHECK_EXN(_fx_catch_140);
         }
         _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___14, &v_609);
         FX_COPY_PTR(v_609.t0, &data_3);
         FX_COPY_PTR(v_609.t1, &ccode_114);
         fx_str_t slit_147 = FX_MAKE_STR("vec");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_147, ctyp_0, ccode_114, &kloc_0, block_stack_ref_0, km_idx_0, &v_610, 0), _fx_catch_140);
         FX_COPY_PTR(v_610.t0, &vec_exp_1);
         FX_COPY_PTR(v_610.t1, &ccode_115);
         FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(data_3, &v_611, 0), _fx_catch_140);
         FX_CALL(
            _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
               &v_612, 0), _fx_catch_140);
         FX_CALL(
            _fx_M10C_gen_codeFM18make_make_vec_callLN15C_form__cstmt_t6N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
               vec_exp_1, v_611, ccode_115, v_612, &kloc_0, km_idx_0, &ccode_116, 0), _fx_catch_140);
         _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, vec_exp_1, ccode_116, &v_1);
      }

   _fx_catch_140: ;
      if (ccode_116) {
         _fx_free_LN15C_form__cstmt_t(&ccode_116);
      }
      if (v_612) {
         _fx_free_N14C_form__cexp_t(&v_612);
      }
      if (v_611) {
         _fx_free_LN14C_form__cexp_t(&v_611);
      }
      if (ccode_115) {
         _fx_free_LN15C_form__cstmt_t(&ccode_115);
      }
      if (vec_exp_1) {
         _fx_free_N14C_form__cexp_t(&vec_exp_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_610);
      if (ccode_114) {
         _fx_free_LN15C_form__cstmt_t(&ccode_114);
      }
      if (data_3) {
         _fx_free_LN14C_form__cexp_t(&data_3);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_609);
      if (elems_2) {
         _fx_free_LT2BN14K_form__atom_t(&elems_2);
      }
      _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___14);
      if (ccode_113) {
         _fx_free_LN15C_form__cstmt_t(&ccode_113);
      }
      if (v_608) {
         _fx_free_N15C_form__cstmt_t(&v_608);
      }
      if (sub_ccode_9) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_9);
      }
      if (call_mkvec_0) {
         _fx_free_N14C_form__cexp_t(&call_mkvec_0);
      }
      if (v_607) {
         _fx_free_LN14C_form__cexp_t(&v_607);
      }
      if (v_606) {
         _fx_free_N14C_form__cexp_t(&v_606);
      }
      if (copy_f_exp_2) {
         _fx_free_N14C_form__cexp_t(&copy_f_exp_2);
      }
      _fx_free_T2BNt6option1N14C_form__cexp_t(&v_605);
      if (free_f_exp_2) {
         _fx_free_N14C_form__cexp_t(&free_f_exp_2);
      }
      _fx_free_T2BNt6option1N14C_form__cexp_t(&v_604);
      if (sizeof_elem_exp_2) {
         _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_2);
      }
      if (v_603) {
         _fx_free_LN14C_form__cexp_t(&v_603);
      }
      if (v_602) {
         _fx_free_N14C_form__cexp_t(&v_602);
      }
      if (sub_ccode_8) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_8);
      }
      if (vec_data_exp_0) {
         _fx_free_N14C_form__cexp_t(&vec_data_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_601);
      if (v_600) {
         _fx_free_LN14C_form__cexp_t(&v_600);
      }
      if (sub_ccode_7) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_7);
      }
      if (tags_exp_1) {
         _fx_free_N14C_form__cexp_t(&tags_exp_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_599);
      if (v_598) {
         _fx_free_N14C_form__ctyp_t(&v_598);
      }
      if (tags_data_6) {
         _fx_free_LN14C_form__cexp_t(&tags_data_6);
      }
      if (v_597) {
         _fx_free_LN14C_form__cexp_t(&v_597);
      }
      if (v_596) {
         _fx_free_LN14C_form__cexp_t(&v_596);
      }
      if (v_595) {
         _fx_free_N14C_form__cexp_t(&v_595);
      }
      if (sub_ccode_6) {
         _fx_free_LN15C_form__cstmt_t(&sub_ccode_6);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_594);
      if (v_593) {
         _fx_free_LN14C_form__cexp_t(&v_593);
      }
      if (ccode_112) {
         _fx_free_LN15C_form__cstmt_t(&ccode_112);
      }
      if (vec_data_0) {
         _fx_free_LN14C_form__cexp_t(&vec_data_0);
      }
      if (tags_data_5) {
         _fx_free_LN14C_form__cexp_t(&tags_data_5);
      }
      if (scalars_data_5) {
         _fx_free_LN14C_form__cexp_t(&scalars_data_5);
      }
      _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_592);
      if (elems_1) {
         _fx_free_LT2BN14K_form__atom_t(&elems_1);
      }
      _fx_free_T5iLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___13);
      if (scalars_exp_1) {
         _fx_free_N14C_form__cexp_t(&scalars_exp_1);
      }
      if (v_591) {
         _fx_free_N14C_form__ctyp_t(&v_591);
      }
      if (elem_ctyp_2) {
         _fx_free_N14C_form__ctyp_t(&elem_ctyp_2);
      }
      if (ccode_111) {
         _fx_free_LN15C_form__cstmt_t(&ccode_111);
      }
      if (vec_exp_0) {
         _fx_free_N14C_form__cexp_t(&vec_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_590);
      if (elems_0) {
         _fx_free_LT2BN14K_form__atom_t(&elems_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 19) {
      fx_exn_t v_645 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_646 = {0};
      _fx_N14C_form__cexp_t arr_exp_5 = 0;
      _fx_LN15C_form__cstmt_t ccode_121 = 0;
      _fx_N14C_form__cexp_t lbl_5 = 0;
      _fx_N14C_form__ctyp_t arr_ctyp_0 = 0;
      _fx_T5N14K_form__atom_tN13Ast__border_tN18Ast__interpolate_tLN13K_form__dom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_12 =
         &kexp_0->u.KExpAt;
      _fx_LN13K_form__dom_t idxs_1 = vcase_12->t3;
      _fx_N13Ast__border_t* border_0 = &vcase_12->t1;
      if (vcase_12->t2.tag != 1) {
         fx_str_t slit_148 = FX_MAKE_STR("cgen: inter-element interpolation is not supported yet");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_148, &v_645, 0), _fx_catch_185);
         FX_THROW(&v_645, false, _fx_catch_185);
      }
      FX_CALL(atom2cexp__0.fp(&vcase_12->t0, false, ccode_0, &kloc_0, &v_646, atom2cexp__0.fcv), _fx_catch_185);
      FX_COPY_PTR(v_646.t0, &arr_exp_5);
      FX_COPY_PTR(v_646.t1, &ccode_121);
      FX_CALL(
         _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &lbl_5, 0), _fx_catch_185);
      FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(arr_exp_5, &arr_ctyp_0, 0), _fx_catch_185);
      int tag_18 = FX_REC_VARIANT_TAG(arr_ctyp_0);
      if (tag_18 == 12) {
         if (idxs_1 != 0) {
            if (idxs_1->tl == 0) {
               _fx_N13K_form__dom_t* v_647 = &idxs_1->hd;
               if (v_647->tag == 2) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_648 = {0};
                  _fx_N14C_form__cexp_t i_exp_2 = 0;
                  _fx_LN15C_form__cstmt_t ccode_122 = 0;
                  _fx_LN14C_form__cexp_t v_649 = 0;
                  _fx_N14C_form__cexp_t get_elem_exp_1 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(&v_647->u.DomainFast, ccode_121, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                        fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_648, atom2cexp_0.fcv), _fx_catch_141);
                  FX_COPY_PTR(v_648.t0, &i_exp_2);
                  FX_COPY_PTR(v_648.t1, &ccode_122);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_2, 0, true, &v_649), _fx_catch_141);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_649, false, &v_649), _fx_catch_141);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g23C_form__std_FX_STR_ELEM, v_649, _fx_g23C_gen_code__CTypUniChar, &kloc_0, &get_elem_exp_1, 0),
                     _fx_catch_141);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, get_elem_exp_1, ccode_122, &v_1);

               _fx_catch_141: ;
                  if (get_elem_exp_1) {
                     _fx_free_N14C_form__cexp_t(&get_elem_exp_1);
                  }
                  if (v_649) {
                     _fx_free_LN14C_form__cexp_t(&v_649);
                  }
                  if (ccode_122) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_122);
                  }
                  if (i_exp_2) {
                     _fx_free_N14C_form__cexp_t(&i_exp_2);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_648);
                  goto _fx_endmatch_19;
               }
            }
         }
         if (idxs_1 != 0) {
            if (idxs_1->tl == 0) {
               _fx_N13K_form__dom_t* v_650 = &idxs_1->hd;
               if (v_650->tag == 1) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_651 = {0};
                  _fx_N14C_form__cexp_t i_exp_3 = 0;
                  _fx_LN15C_form__cstmt_t ccode_123 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_652 = {0};
                  _fx_N14C_form__cexp_t get_elem_exp_2 = 0;
                  _fx_LN15C_form__cstmt_t ccode_124 = 0;
                  FX_CALL(atom2cexp__0.fp(&v_650->u.DomainElem, true, ccode_121, &kloc_0, &v_651, atom2cexp__0.fcv),
                     _fx_catch_146);
                  FX_COPY_PTR(v_651.t0, &i_exp_3);
                  FX_COPY_PTR(v_651.t1, &ccode_123);
                  int tag_19 = border_0->tag;
                  if (tag_19 == 1) {
                     _fx_LN14C_form__cexp_t v_653 = 0;
                     _fx_N14C_form__cexp_t chk_exp_0 = 0;
                     _fx_LN14C_form__cexp_t v_654 = 0;
                     _fx_N14C_form__cexp_t v_655 = 0;
                     _fx_N15C_form__cstmt_t v_656 = 0;
                     _fx_LN15C_form__cstmt_t v_657 = 0;
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_5, 0, true, &v_653), _fx_catch_142);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_3, v_653, false, &v_653), _fx_catch_142);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_653, false, &v_653), _fx_catch_142);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g25C_form__std_FX_STR_CHKIDX, v_653, _fx_g20C_gen_code__CTypVoid, &kloc_0, &chk_exp_0, 0),
                        _fx_catch_142);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_3, 0, true, &v_654), _fx_catch_142);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_654, false, &v_654), _fx_catch_142);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g23C_form__std_FX_STR_ELEM, v_654, _fx_g23C_gen_code__CTypUniChar, &kloc_0, &v_655, 0),
                        _fx_catch_142);
                     FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(chk_exp_0, &v_656), _fx_catch_142);
                     FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_656, ccode_123, true, &v_657), _fx_catch_142);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_655, v_657, &v_652);

                  _fx_catch_142: ;
                     if (v_657) {
                        _fx_free_LN15C_form__cstmt_t(&v_657);
                     }
                     if (v_656) {
                        _fx_free_N15C_form__cstmt_t(&v_656);
                     }
                     if (v_655) {
                        _fx_free_N14C_form__cexp_t(&v_655);
                     }
                     if (v_654) {
                        _fx_free_LN14C_form__cexp_t(&v_654);
                     }
                     if (chk_exp_0) {
                        _fx_free_N14C_form__cexp_t(&chk_exp_0);
                     }
                     if (v_653) {
                        _fx_free_LN14C_form__cexp_t(&v_653);
                     }
                  }
                  else if (tag_19 == 2) {
                     _fx_LN14C_form__cexp_t v_658 = 0;
                     _fx_N14C_form__cexp_t v_659 = 0;
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_3, 0, true, &v_658), _fx_catch_143);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_658, false, &v_658), _fx_catch_143);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g28C_form__std_FX_STR_ELEM_CLIP, v_658, _fx_g23C_gen_code__CTypUniChar, &kloc_0, &v_659, 0),
                        _fx_catch_143);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_659, ccode_123, &v_652);

                  _fx_catch_143: ;
                     if (v_659) {
                        _fx_free_N14C_form__cexp_t(&v_659);
                     }
                     if (v_658) {
                        _fx_free_LN14C_form__cexp_t(&v_658);
                     }
                  }
                  else if (tag_19 == 3) {
                     _fx_LN14C_form__cexp_t v_660 = 0;
                     _fx_N14C_form__cexp_t v_661 = 0;
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_3, 0, true, &v_660), _fx_catch_144);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_660, false, &v_660), _fx_catch_144);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g28C_form__std_FX_STR_ELEM_WRAP, v_660, _fx_g23C_gen_code__CTypUniChar, &kloc_0, &v_661, 0),
                        _fx_catch_144);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_661, ccode_123, &v_652);

                  _fx_catch_144: ;
                     if (v_661) {
                        _fx_free_N14C_form__cexp_t(&v_661);
                     }
                     if (v_660) {
                        _fx_free_LN14C_form__cexp_t(&v_660);
                     }
                  }
                  else if (tag_19 == 4) {
                     _fx_LN14C_form__cexp_t v_662 = 0;
                     _fx_N14C_form__cexp_t v_663 = 0;
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_3, 0, true, &v_662), _fx_catch_145);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_662, false, &v_662), _fx_catch_145);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g28C_form__std_FX_STR_ELEM_ZERO, v_662, _fx_g23C_gen_code__CTypUniChar, &kloc_0, &v_663, 0),
                        _fx_catch_145);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_663, ccode_123, &v_652);

                  _fx_catch_145: ;
                     if (v_663) {
                        _fx_free_N14C_form__cexp_t(&v_663);
                     }
                     if (v_662) {
                        _fx_free_LN14C_form__cexp_t(&v_662);
                     }
                  }
                  else {
                     FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_146);
                  }
                  FX_CHECK_EXN(_fx_catch_146);
                  FX_COPY_PTR(v_652.t0, &get_elem_exp_2);
                  FX_COPY_PTR(v_652.t1, &ccode_124);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, get_elem_exp_2, ccode_124, &v_1);

               _fx_catch_146: ;
                  if (ccode_124) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_124);
                  }
                  if (get_elem_exp_2) {
                     _fx_free_N14C_form__cexp_t(&get_elem_exp_2);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_652);
                  if (ccode_123) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_123);
                  }
                  if (i_exp_3) {
                     _fx_free_N14C_form__cexp_t(&i_exp_3);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_651);
                  goto _fx_endmatch_19;
               }
            }
         }
         if (idxs_1 != 0) {
            if (idxs_1->tl == 0) {
               _fx_N13K_form__dom_t* v_664 = &idxs_1->hd;
               if (v_664->tag == 3) {
                  fx_exn_t v_665 = {0};
                  _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t v_666 = {0};
                  _fx_N14C_form__cexp_t a_exp_1 = 0;
                  _fx_LN15C_form__cstmt_t ccode_125 = 0;
                  _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t v_667 = {0};
                  _fx_N14C_form__cexp_t b_exp_1 = 0;
                  _fx_LN15C_form__cstmt_t ccode_126 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_668 = {0};
                  _fx_N14C_form__cexp_t delta_exp_1 = 0;
                  _fx_LN15C_form__cstmt_t ccode_127 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_669 = {0};
                  _fx_N14C_form__cexp_t substr_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_128 = 0;
                  _fx_N14C_form__cexp_t v_670 = 0;
                  _fx_N14C_form__cexp_t v_671 = 0;
                  _fx_N14C_form__cexp_t v_672 = 0;
                  _fx_LN14C_form__cexp_t v_673 = 0;
                  _fx_N14C_form__cexp_t call_substr_0 = 0;
                  _fx_LN15C_form__cstmt_t v_674 = 0;
                  _fx_Ta3N14K_form__atom_t* vcase_13 = &v_664->u.DomainRange;
                  _fx_N14K_form__atom_t* b_0 = &vcase_13->t1;
                  _fx_N14K_form__atom_t* a_8 = &vcase_13->t0;
                  if (border_0->tag != 1) {
                     fx_str_t slit_149 = FX_MAKE_STR("cgen: border extrapolation with ranges is not supported yet");
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_149, &v_665, 0), _fx_catch_151);
                     FX_THROW(&v_665, false, _fx_catch_151);
                  }
                  if (a_8->tag == 2) {
                     if (a_8->u.AtomLit.tag == 8) {
                        _fx_N14C_form__cexp_t v_675 = 0;
                        _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_676 = {0};
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_675, 0),
                           _fx_catch_147);
                        _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_675, ccode_121, &v_676);
                        _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(1, &v_676, &v_666);

                     _fx_catch_147: ;
                        _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_676);
                        if (v_675) {
                           _fx_free_N14C_form__cexp_t(&v_675);
                        }
                        goto _fx_endmatch_17;
                     }
                  }
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_677 = {0};
                  FX_CALL(
                     atom2cexp_0.fp(a_8, ccode_121, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                        km_idx_0, &v_677, atom2cexp_0.fcv), _fx_catch_148);
                  _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(0, &v_677, &v_666);

               _fx_catch_148: ;
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_677);

               _fx_endmatch_17: ;
                  FX_CHECK_EXN(_fx_catch_151);
                  int_ mask_0 = v_666.t0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* v_678 = &v_666.t1;
                  FX_COPY_PTR(v_678->t0, &a_exp_1);
                  FX_COPY_PTR(v_678->t1, &ccode_125);
                  if (b_0->tag == 2) {
                     if (b_0->u.AtomLit.tag == 8) {
                        _fx_N14C_form__cexp_t v_679 = 0;
                        _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_680 = {0};
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_679, 0),
                           _fx_catch_149);
                        _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_679, ccode_125, &v_680);
                        _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(2 + mask_0, &v_680, &v_667);

                     _fx_catch_149: ;
                        _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_680);
                        if (v_679) {
                           _fx_free_N14C_form__cexp_t(&v_679);
                        }
                        goto _fx_endmatch_18;
                     }
                  }
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_681 = {0};
                  FX_CALL(
                     atom2cexp_0.fp(b_0, ccode_125, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                        km_idx_0, &v_681, atom2cexp_0.fcv), _fx_catch_150);
                  _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(mask_0, &v_681, &v_667);

               _fx_catch_150: ;
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_681);

               _fx_endmatch_18: ;
                  FX_CHECK_EXN(_fx_catch_151);
                  int_ mask_1 = v_667.t0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* v_682 = &v_667.t1;
                  FX_COPY_PTR(v_682->t0, &b_exp_1);
                  FX_COPY_PTR(v_682->t1, &ccode_126);
                  FX_CALL(
                     atom2cexp_0.fp(&vcase_13->t2, ccode_126, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_668, atom2cexp_0.fcv), _fx_catch_151);
                  FX_COPY_PTR(v_668.t0, &delta_exp_1);
                  FX_COPY_PTR(v_668.t1, &ccode_127);
                  fx_str_t slit_150 = FX_MAKE_STR("substr");
                  FX_CALL(
                     _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                        dstexp_r_0, &slit_150, ctyp_0, ccode_127, &kloc_0, block_stack_ref_0, km_idx_0, &v_669, 0),
                     _fx_catch_151);
                  FX_COPY_PTR(v_669.t0, &substr_exp_0);
                  FX_COPY_PTR(v_669.t1, &ccode_128);
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_5, &v_670, 0),
                     _fx_catch_151);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(mask_1, &kloc_0, &v_671, 0),
                     _fx_catch_151);
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(substr_exp_0, &v_672, 0),
                     _fx_catch_151);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_672, 0, true, &v_673), _fx_catch_151);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_671, v_673, false, &v_673), _fx_catch_151);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(delta_exp_1, v_673, false, &v_673), _fx_catch_151);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(b_exp_1, v_673, false, &v_673), _fx_catch_151);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(a_exp_1, v_673, false, &v_673), _fx_catch_151);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_670, v_673, false, &v_673), _fx_catch_151);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g21C_form__std_fx_substr, v_673, _fx_g22C_gen_code__CTypString, &kloc_0, &call_substr_0, 0),
                     _fx_catch_151);
                  FX_CALL(
                     _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                        call_substr_0, ccode_128, &kloc_0, block_stack_ref_0, &v_674, 0), _fx_catch_151);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, substr_exp_0, v_674, &v_1);

               _fx_catch_151: ;
                  if (v_674) {
                     _fx_free_LN15C_form__cstmt_t(&v_674);
                  }
                  if (call_substr_0) {
                     _fx_free_N14C_form__cexp_t(&call_substr_0);
                  }
                  if (v_673) {
                     _fx_free_LN14C_form__cexp_t(&v_673);
                  }
                  if (v_672) {
                     _fx_free_N14C_form__cexp_t(&v_672);
                  }
                  if (v_671) {
                     _fx_free_N14C_form__cexp_t(&v_671);
                  }
                  if (v_670) {
                     _fx_free_N14C_form__cexp_t(&v_670);
                  }
                  if (ccode_128) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_128);
                  }
                  if (substr_exp_0) {
                     _fx_free_N14C_form__cexp_t(&substr_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_669);
                  if (ccode_127) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_127);
                  }
                  if (delta_exp_1) {
                     _fx_free_N14C_form__cexp_t(&delta_exp_1);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_668);
                  if (ccode_126) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_126);
                  }
                  if (b_exp_1) {
                     _fx_free_N14C_form__cexp_t(&b_exp_1);
                  }
                  _fx_free_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(&v_667);
                  if (ccode_125) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_125);
                  }
                  if (a_exp_1) {
                     _fx_free_N14C_form__cexp_t(&a_exp_1);
                  }
                  _fx_free_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(&v_666);
                  fx_free_exn(&v_665);
                  goto _fx_endmatch_19;
               }
            }
         }
         fx_exn_t v_683 = {0};
         fx_str_t slit_151 =
            FX_MAKE_STR("cgen: unexpected index type when accessing string (should be a single scalar index or range)");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_151, &v_683, 0), _fx_catch_152);
         FX_THROW(&v_683, false, _fx_catch_152);

      _fx_catch_152: ;
         fx_free_exn(&v_683);

      _fx_endmatch_19: ;
         FX_CHECK_EXN(_fx_catch_153);

      _fx_catch_153: ;
      }
      else if (tag_18 == 20) {
         if (idxs_1 != 0) {
            if (idxs_1->tl == 0) {
               _fx_N13K_form__dom_t* v_684 = &idxs_1->hd;
               if (v_684->tag == 2) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_685 = {0};
                  _fx_N14C_form__cexp_t i_exp_4 = 0;
                  _fx_LN15C_form__cstmt_t ccode_129 = 0;
                  _fx_N14C_form__cexp_t v_686 = 0;
                  _fx_LN14C_form__cexp_t v_687 = 0;
                  _fx_N14C_form__cexp_t get_elem_exp_3 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(&v_684->u.DomainFast, ccode_121, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                        fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_685, atom2cexp_0.fcv), _fx_catch_154);
                  FX_COPY_PTR(v_685.t0, &i_exp_4);
                  FX_COPY_PTR(v_685.t1, &ccode_129);
                  _fx_R9Ast__id_t v_688;
                  fx_str_t slit_152 = FX_MAKE_STR("FX_RRB_ELEM");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_152, &v_688, 0), _fx_catch_154);
                  FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_686),
                     _fx_catch_154);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_4, 0, true, &v_687), _fx_catch_154);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_687, false, &v_687), _fx_catch_154);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_686, v_687, false, &v_687), _fx_catch_154);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_688, v_687, ctyp_0, &kloc_0, &get_elem_exp_3, 0), _fx_catch_154);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, get_elem_exp_3, ccode_129, &v_1);

               _fx_catch_154: ;
                  if (get_elem_exp_3) {
                     _fx_free_N14C_form__cexp_t(&get_elem_exp_3);
                  }
                  if (v_687) {
                     _fx_free_LN14C_form__cexp_t(&v_687);
                  }
                  if (v_686) {
                     _fx_free_N14C_form__cexp_t(&v_686);
                  }
                  if (ccode_129) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_129);
                  }
                  if (i_exp_4) {
                     _fx_free_N14C_form__cexp_t(&i_exp_4);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_685);
                  goto _fx_endmatch_24;
               }
            }
         }
         if (idxs_1 != 0) {
            if (idxs_1->tl == 0) {
               _fx_N13K_form__dom_t* v_689 = &idxs_1->hd;
               if (v_689->tag == 1) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_690 = {0};
                  _fx_N14C_form__cexp_t i_exp_5 = 0;
                  _fx_LN15C_form__cstmt_t ccode_130 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_691 = {0};
                  _fx_N14C_form__cexp_t get_elem_exp_4 = 0;
                  _fx_LN15C_form__cstmt_t ccode_131 = 0;
                  FX_CALL(atom2cexp__0.fp(&v_689->u.DomainElem, true, ccode_121, &kloc_0, &v_690, atom2cexp__0.fcv),
                     _fx_catch_159);
                  FX_COPY_PTR(v_690.t0, &i_exp_5);
                  FX_COPY_PTR(v_690.t1, &ccode_130);
                  int tag_20 = border_0->tag;
                  if (tag_20 == 1) {
                     _fx_LN14C_form__cexp_t v_692 = 0;
                     _fx_N14C_form__cexp_t chk_exp_1 = 0;
                     _fx_N14C_form__cexp_t v_693 = 0;
                     _fx_LN14C_form__cexp_t v_694 = 0;
                     _fx_N14C_form__cexp_t get_elem_exp_5 = 0;
                     _fx_N15C_form__cstmt_t v_695 = 0;
                     _fx_LN15C_form__cstmt_t v_696 = 0;
                     _fx_R9Ast__id_t v_697;
                     fx_str_t slit_153 = FX_MAKE_STR("FX_RRB_CHKIDX");
                     FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_153, &v_697, 0), _fx_catch_155);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_5, 0, true, &v_692), _fx_catch_155);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_5, v_692, false, &v_692), _fx_catch_155);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_692, false, &v_692), _fx_catch_155);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_697, v_692, _fx_g20C_gen_code__CTypVoid, &kloc_0, &chk_exp_1, 0), _fx_catch_155);
                     _fx_R9Ast__id_t v_698;
                     fx_str_t slit_154 = FX_MAKE_STR("FX_RRB_ELEM");
                     FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_154, &v_698, 0), _fx_catch_155);
                     FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_693),
                        _fx_catch_155);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_5, 0, true, &v_694), _fx_catch_155);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_694, false, &v_694), _fx_catch_155);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_693, v_694, false, &v_694), _fx_catch_155);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_698, v_694, ctyp_0, &kloc_0, &get_elem_exp_5, 0), _fx_catch_155);
                     FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(chk_exp_1, &v_695), _fx_catch_155);
                     FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_695, ccode_130, true, &v_696), _fx_catch_155);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(get_elem_exp_5, v_696, &v_691);

                  _fx_catch_155: ;
                     if (v_696) {
                        _fx_free_LN15C_form__cstmt_t(&v_696);
                     }
                     if (v_695) {
                        _fx_free_N15C_form__cstmt_t(&v_695);
                     }
                     if (get_elem_exp_5) {
                        _fx_free_N14C_form__cexp_t(&get_elem_exp_5);
                     }
                     if (v_694) {
                        _fx_free_LN14C_form__cexp_t(&v_694);
                     }
                     if (v_693) {
                        _fx_free_N14C_form__cexp_t(&v_693);
                     }
                     if (chk_exp_1) {
                        _fx_free_N14C_form__cexp_t(&chk_exp_1);
                     }
                     if (v_692) {
                        _fx_free_LN14C_form__cexp_t(&v_692);
                     }
                  }
                  else if (tag_20 == 2) {
                     _fx_N14C_form__cexp_t v_699 = 0;
                     _fx_LN14C_form__cexp_t v_700 = 0;
                     _fx_N14C_form__cexp_t get_elem_exp_6 = 0;
                     _fx_R9Ast__id_t v_701;
                     fx_str_t slit_155 = FX_MAKE_STR("FX_RRB_ELEM_CLIP");
                     FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_155, &v_701, 0), _fx_catch_156);
                     FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_699),
                        _fx_catch_156);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_5, 0, true, &v_700), _fx_catch_156);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_700, false, &v_700), _fx_catch_156);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_699, v_700, false, &v_700), _fx_catch_156);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_701, v_700, ctyp_0, &kloc_0, &get_elem_exp_6, 0), _fx_catch_156);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(get_elem_exp_6, ccode_130, &v_691);

                  _fx_catch_156: ;
                     if (get_elem_exp_6) {
                        _fx_free_N14C_form__cexp_t(&get_elem_exp_6);
                     }
                     if (v_700) {
                        _fx_free_LN14C_form__cexp_t(&v_700);
                     }
                     if (v_699) {
                        _fx_free_N14C_form__cexp_t(&v_699);
                     }
                  }
                  else if (tag_20 == 3) {
                     _fx_N14C_form__cexp_t v_702 = 0;
                     _fx_LN14C_form__cexp_t v_703 = 0;
                     _fx_N14C_form__cexp_t get_elem_exp_7 = 0;
                     _fx_R9Ast__id_t v_704;
                     fx_str_t slit_156 = FX_MAKE_STR("FX_RRB_ELEM_WRAP");
                     FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_156, &v_704, 0), _fx_catch_157);
                     FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_702),
                        _fx_catch_157);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_5, 0, true, &v_703), _fx_catch_157);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_703, false, &v_703), _fx_catch_157);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_702, v_703, false, &v_703), _fx_catch_157);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_704, v_703, ctyp_0, &kloc_0, &get_elem_exp_7, 0), _fx_catch_157);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(get_elem_exp_7, ccode_130, &v_691);

                  _fx_catch_157: ;
                     if (get_elem_exp_7) {
                        _fx_free_N14C_form__cexp_t(&get_elem_exp_7);
                     }
                     if (v_703) {
                        _fx_free_LN14C_form__cexp_t(&v_703);
                     }
                     if (v_702) {
                        _fx_free_N14C_form__cexp_t(&v_702);
                     }
                  }
                  else if (tag_20 == 4) {
                     _fx_N14C_form__cexp_t v_705 = 0;
                     _fx_LN14C_form__cexp_t v_706 = 0;
                     _fx_N14C_form__cexp_t get_elem_exp_8 = 0;
                     _fx_R9Ast__id_t v_707;
                     fx_str_t slit_157 = FX_MAKE_STR("FX_RRB_ELEM_ZERO");
                     FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_157, &v_707, 0), _fx_catch_158);
                     FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_705),
                        _fx_catch_158);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_5, 0, true, &v_706), _fx_catch_158);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_706, false, &v_706), _fx_catch_158);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_705, v_706, false, &v_706), _fx_catch_158);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_707, v_706, ctyp_0, &kloc_0, &get_elem_exp_8, 0), _fx_catch_158);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(get_elem_exp_8, ccode_130, &v_691);

                  _fx_catch_158: ;
                     if (get_elem_exp_8) {
                        _fx_free_N14C_form__cexp_t(&get_elem_exp_8);
                     }
                     if (v_706) {
                        _fx_free_LN14C_form__cexp_t(&v_706);
                     }
                     if (v_705) {
                        _fx_free_N14C_form__cexp_t(&v_705);
                     }
                  }
                  else {
                     FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_159);
                  }
                  FX_CHECK_EXN(_fx_catch_159);
                  FX_COPY_PTR(v_691.t0, &get_elem_exp_4);
                  FX_COPY_PTR(v_691.t1, &ccode_131);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, get_elem_exp_4, ccode_131, &v_1);

               _fx_catch_159: ;
                  if (ccode_131) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_131);
                  }
                  if (get_elem_exp_4) {
                     _fx_free_N14C_form__cexp_t(&get_elem_exp_4);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_691);
                  if (ccode_130) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_130);
                  }
                  if (i_exp_5) {
                     _fx_free_N14C_form__cexp_t(&i_exp_5);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_690);
                  goto _fx_endmatch_24;
               }
            }
         }
         if (idxs_1 != 0) {
            if (idxs_1->tl == 0) {
               _fx_N13K_form__dom_t* v_708 = &idxs_1->hd;
               if (v_708->tag == 3) {
                  fx_exn_t v_709 = {0};
                  _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t v_710 = {0};
                  _fx_N14C_form__cexp_t a_exp_2 = 0;
                  _fx_LN15C_form__cstmt_t ccode_132 = 0;
                  _fx_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t v_711 = {0};
                  _fx_N14C_form__cexp_t b_exp_2 = 0;
                  _fx_LN15C_form__cstmt_t ccode_133 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_712 = {0};
                  _fx_N14C_form__cexp_t slice_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_134 = 0;
                  _fx_N14C_form__cexp_t v_713 = 0;
                  _fx_N14C_form__cexp_t v_714 = 0;
                  _fx_N14C_form__cexp_t v_715 = 0;
                  _fx_N14C_form__cexp_t v_716 = 0;
                  _fx_LN14C_form__cexp_t v_717 = 0;
                  _fx_N14C_form__cexp_t call_slice_0 = 0;
                  _fx_LN15C_form__cstmt_t v_718 = 0;
                  _fx_Ta3N14K_form__atom_t* vcase_14 = &v_708->u.DomainRange;
                  _fx_N14K_form__atom_t* delta_0 = &vcase_14->t2;
                  _fx_N14K_form__atom_t* b_1 = &vcase_14->t1;
                  _fx_N14K_form__atom_t* a_9 = &vcase_14->t0;
                  if (border_0->tag != 1) {
                     fx_str_t slit_158 = FX_MAKE_STR("cgen: border extrapolation with ranges is not supported yet");
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_158, &v_709, 0), _fx_catch_165);
                     FX_THROW(&v_709, false, _fx_catch_165);
                  }
                  if (a_9->tag == 2) {
                     if (a_9->u.AtomLit.tag == 8) {
                        _fx_N14C_form__cexp_t v_719 = 0;
                        _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_720 = {0};
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_719, 0),
                           _fx_catch_160);
                        _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_719, ccode_121, &v_720);
                        _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(1, &v_720, &v_710);

                     _fx_catch_160: ;
                        _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_720);
                        if (v_719) {
                           _fx_free_N14C_form__cexp_t(&v_719);
                        }
                        goto _fx_endmatch_20;
                     }
                  }
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_721 = {0};
                  FX_CALL(
                     atom2cexp_0.fp(a_9, ccode_121, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                        km_idx_0, &v_721, atom2cexp_0.fcv), _fx_catch_161);
                  _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(0, &v_721, &v_710);

               _fx_catch_161: ;
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_721);

               _fx_endmatch_20: ;
                  FX_CHECK_EXN(_fx_catch_165);
                  int_ mask_2 = v_710.t0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* v_722 = &v_710.t1;
                  FX_COPY_PTR(v_722->t0, &a_exp_2);
                  FX_COPY_PTR(v_722->t1, &ccode_132);
                  if (b_1->tag == 2) {
                     if (b_1->u.AtomLit.tag == 8) {
                        _fx_N14C_form__cexp_t v_723 = 0;
                        _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_724 = {0};
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_723, 0),
                           _fx_catch_162);
                        _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_723, ccode_132, &v_724);
                        _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(2 + mask_2, &v_724, &v_711);

                     _fx_catch_162: ;
                        _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_724);
                        if (v_723) {
                           _fx_free_N14C_form__cexp_t(&v_723);
                        }
                        goto _fx_endmatch_21;
                     }
                  }
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_725 = {0};
                  FX_CALL(
                     atom2cexp_0.fp(b_1, ccode_132, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                        km_idx_0, &v_725, atom2cexp_0.fcv), _fx_catch_163);
                  _fx_make_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(mask_2, &v_725, &v_711);

               _fx_catch_163: ;
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_725);

               _fx_endmatch_21: ;
                  FX_CHECK_EXN(_fx_catch_165);
                  int_ mask_3 = v_711.t0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* v_726 = &v_711.t1;
                  FX_COPY_PTR(v_726->t0, &b_exp_2);
                  FX_COPY_PTR(v_726->t1, &ccode_133);
                  int tag_21 = delta_0->tag;
                  int_ delta_1;
                  bool res_18;
                  if (tag_21 == 2) {
                     if (delta_0->u.AtomLit.tag == 8) {
                        res_18 = true; goto _fx_endmatch_22;
                     }
                  }
                  if (tag_21 == 2) {
                     _fx_N14K_form__klit_t* v_727 = &delta_0->u.AtomLit;
                     if (v_727->tag == 1) {
                        if (v_727->u.KLitInt == 1LL) {
                           res_18 = true; goto _fx_endmatch_22;
                        }
                     }
                  }
                  res_18 = false;

               _fx_endmatch_22: ;
                  FX_CHECK_EXN(_fx_catch_165);
                  if (res_18) {
                     delta_1 = 1; goto _fx_endmatch_23;
                  }
                  if (tag_21 == 2) {
                     _fx_N14K_form__klit_t* v_728 = &delta_0->u.AtomLit;
                     if (v_728->tag == 1) {
                        if (v_728->u.KLitInt == -1LL) {
                           delta_1 = -1; goto _fx_endmatch_23;
                        }
                     }
                  }
                  fx_exn_t v_729 = {0};
                  fx_str_t slit_159 = FX_MAKE_STR("cgen: vector slicing only supports stride == ±1");
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_159, &v_729, 0), _fx_catch_164);
                  FX_THROW(&v_729, false, _fx_catch_164);

               _fx_catch_164: ;
                  fx_free_exn(&v_729);

               _fx_endmatch_23: ;
                  FX_CHECK_EXN(_fx_catch_165);
                  fx_str_t slit_160 = FX_MAKE_STR("slice");
                  FX_CALL(
                     _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                        dstexp_r_0, &slit_160, ctyp_0, ccode_133, &kloc_0, block_stack_ref_0, km_idx_0, &v_712, 0),
                     _fx_catch_165);
                  FX_COPY_PTR(v_712.t0, &slice_exp_0);
                  FX_COPY_PTR(v_712.t1, &ccode_134);
                  _fx_R9Ast__id_t v_730;
                  fx_str_t slit_161 = FX_MAKE_STR("fx_rrb_slice");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_161, &v_730, 0), _fx_catch_165);
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_5, &v_713, 0),
                     _fx_catch_165);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(delta_1, &kloc_0, &v_714, 0),
                     _fx_catch_165);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(mask_3, &kloc_0, &v_715, 0),
                     _fx_catch_165);
                  FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(slice_exp_0, &v_716, 0),
                     _fx_catch_165);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_716, 0, true, &v_717), _fx_catch_165);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_715, v_717, false, &v_717), _fx_catch_165);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_714, v_717, false, &v_717), _fx_catch_165);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(b_exp_2, v_717, false, &v_717), _fx_catch_165);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(a_exp_2, v_717, false, &v_717), _fx_catch_165);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_713, v_717, false, &v_717), _fx_catch_165);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_730, v_717, ctyp_0, &kloc_0, &call_slice_0, 0), _fx_catch_165);
                  FX_CALL(
                     _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                        call_slice_0, ccode_134, &kloc_0, block_stack_ref_0, &v_718, 0), _fx_catch_165);
                  _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, slice_exp_0, v_718, &v_1);

               _fx_catch_165: ;
                  if (v_718) {
                     _fx_free_LN15C_form__cstmt_t(&v_718);
                  }
                  if (call_slice_0) {
                     _fx_free_N14C_form__cexp_t(&call_slice_0);
                  }
                  if (v_717) {
                     _fx_free_LN14C_form__cexp_t(&v_717);
                  }
                  if (v_716) {
                     _fx_free_N14C_form__cexp_t(&v_716);
                  }
                  if (v_715) {
                     _fx_free_N14C_form__cexp_t(&v_715);
                  }
                  if (v_714) {
                     _fx_free_N14C_form__cexp_t(&v_714);
                  }
                  if (v_713) {
                     _fx_free_N14C_form__cexp_t(&v_713);
                  }
                  if (ccode_134) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_134);
                  }
                  if (slice_exp_0) {
                     _fx_free_N14C_form__cexp_t(&slice_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_712);
                  if (ccode_133) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_133);
                  }
                  if (b_exp_2) {
                     _fx_free_N14C_form__cexp_t(&b_exp_2);
                  }
                  _fx_free_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(&v_711);
                  if (ccode_132) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_132);
                  }
                  if (a_exp_2) {
                     _fx_free_N14C_form__cexp_t(&a_exp_2);
                  }
                  _fx_free_T2iT2N14C_form__cexp_tLN15C_form__cstmt_t(&v_710);
                  fx_free_exn(&v_709);
                  goto _fx_endmatch_24;
               }
            }
         }
         fx_exn_t v_731 = {0};
         fx_str_t slit_162 =
            FX_MAKE_STR("cgen: unexpected index type when accessing vector (should be a single scalar index or range)");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_162, &v_731, 0), _fx_catch_166);
         FX_THROW(&v_731, false, _fx_catch_166);

      _fx_catch_166: ;
         fx_free_exn(&v_731);

      _fx_endmatch_24: ;
         FX_CHECK_EXN(_fx_catch_167);

      _fx_catch_167: ;
      }
      else if (tag_18 == 19) {
         _fx_LN13K_form__dom_t idxs_2 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_732 = {0};
         _fx_N14C_form__cexp_t subarr_exp_0 = 0;
         _fx_N14C_form__cexp_t v_733 = 0;
         _fx_N14C_form__cexp_t v_734 = 0;
         _fx_LN14C_form__cexp_t v_735 = 0;
         _fx_N14C_form__cexp_t call_flatten_0 = 0;
         _fx_LN15C_form__cstmt_t v_736 = 0;
         fx_exn_t v_737 = {0};
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___16 = {0};
         _fx_LN13K_form__dom_t idxs_3 = 0;
         _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_738 = {0};
         _fx_LN14C_form__cexp_t range_data_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_135 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_739 = {0};
         _fx_N14C_form__cexp_t subarr_exp_1 = 0;
         _fx_LN15C_form__cstmt_t ccode_136 = 0;
         _fx_LN19C_form__ctyp_attr_t v_740 = 0;
         _fx_N14C_form__ctyp_t rdata_ctyp_0 = 0;
         _fx_LN14C_form__cexp_t v_741 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_742 = {0};
         _fx_N14C_form__cexp_t rdata_arr_0 = 0;
         _fx_R16Ast__val_flags_t v_743 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_744 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_745 = {0};
         _fx_N14C_form__cexp_t rdata_exp_0 = 0;
         _fx_LN15C_form__cstmt_t sub_ccode_10 = 0;
         _fx_N14C_form__cexp_t v_746 = 0;
         _fx_N14C_form__cexp_t v_747 = 0;
         _fx_LN14C_form__cexp_t v_748 = 0;
         _fx_N14C_form__cexp_t call_subarr_0 = 0;
         _fx_LN15C_form__cstmt_t sub_ccode_11 = 0;
         _fx_N15C_form__cstmt_t v_749 = 0;
         _fx_LN15C_form__cstmt_t ccode_137 = 0;
         _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t __fold_result___17 = {0};
         _fx_LN13K_form__dom_t idxs_4 = 0;
         _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_750 = {0};
         _fx_Nt6option1N14C_form__cexp_t chk_exp_opt_0 = {0};
         _fx_LN14C_form__cexp_t i_exps_3 = 0;
         _fx_LN15C_form__cstmt_t ccode_138 = 0;
         _fx_LN15C_form__cstmt_t ccode_139 = 0;
         _fx_LR9Ast__id_t access_op_0 = 0;
         _fx_N14C_form__cexp_t v_751 = 0;
         _fx_LN14C_form__cexp_t v_752 = 0;
         _fx_LN14C_form__cexp_t v_753 = 0;
         _fx_N14C_form__ctyp_t v_754 = 0;
         _fx_N14C_form__cexp_t get_elem_exp_9 = 0;
         _fx_N14C_form__cexp_t v_755 = 0;
         bool __fold_result___18 = false;
         FX_COPY_PTR(idxs_1, &idxs_2);
         _fx_LN13K_form__dom_t lst_19 = idxs_2;
         for (; lst_19; lst_19 = lst_19->tl) {
            _fx_N13K_form__dom_t* d_0 = &lst_19->hd;
            bool res_19;
            if (d_0->tag == 3) {
               res_19 = true;
            }
            else {
               res_19 = false;
            }
            FX_CHECK_EXN(_fx_catch_168);
            if (res_19) {
               __fold_result___18 = true; FX_BREAK(_fx_catch_168);
            }

         _fx_catch_168: ;
            FX_CHECK_BREAK();
            FX_CHECK_EXN(_fx_catch_183);
         }
         bool need_subarr_0 = __fold_result___18;
         bool need_flatten_0;
         if (need_subarr_0) {
            bool res_20;
            if (idxs_1 != 0) {
               if (idxs_1->tl == 0) {
                  _fx_N13K_form__dom_t* v_756 = &idxs_1->hd;
                  if (v_756->tag == 3) {
                     _fx_Ta3N14K_form__atom_t* vcase_15 = &v_756->u.DomainRange;
                     _fx_N14K_form__atom_t* v_757 = &vcase_15->t0;
                     if (v_757->tag == 2) {
                        _fx_N14K_form__atom_t* v_758 = &vcase_15->t1;
                        if (v_758->tag == 2) {
                           _fx_N14K_form__atom_t* v_759 = &vcase_15->t2;
                           if (v_759->tag == 2) {
                              if (v_757->u.AtomLit.tag == 8) {
                                 if (v_758->u.AtomLit.tag == 8) {
                                    if (v_759->u.AtomLit.tag == 8) {
                                       res_20 = true; goto _fx_endmatch_25;
                                    }
                                 }
                              }
                           }
                        }
                     }
                  }
               }
            }
            if (idxs_1 != 0) {
               if (idxs_1->tl == 0) {
                  _fx_N13K_form__dom_t* v_760 = &idxs_1->hd;
                  if (v_760->tag == 3) {
                     _fx_Ta3N14K_form__atom_t* vcase_16 = &v_760->u.DomainRange;
                     _fx_N14K_form__atom_t* v_761 = &vcase_16->t0;
                     if (v_761->tag == 2) {
                        _fx_N14K_form__atom_t* v_762 = &vcase_16->t1;
                        if (v_762->tag == 2) {
                           _fx_N14K_form__atom_t* v_763 = &vcase_16->t2;
                           if (v_763->tag == 2) {
                              if (v_761->u.AtomLit.tag == 8) {
                                 if (v_762->u.AtomLit.tag == 8) {
                                    _fx_N14K_form__klit_t* v_764 = &v_763->u.AtomLit;
                                    if (v_764->tag == 1) {
                                       if (v_764->u.KLitInt == 1LL) {
                                          res_20 = true; goto _fx_endmatch_25;
                                       }
                                    }
                                 }
                              }
                           }
                        }
                     }
                  }
               }
            }
            res_20 = false;

         _fx_endmatch_25: ;
            FX_CHECK_EXN(_fx_catch_183);
            if (res_20) {
               need_flatten_0 = true; goto _fx_endmatch_26;
            }
            need_flatten_0 = false;

         _fx_endmatch_26: ;
            FX_CHECK_EXN(_fx_catch_183);
         }
         else {
            need_flatten_0 = false;
         }
         if (need_flatten_0) {
            fx_str_t slit_163 = FX_MAKE_STR("arr");
            FX_CALL(
               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                  dstexp_r_0, &slit_163, ctyp_0, ccode_121, &kloc_0, block_stack_ref_0, km_idx_0, &v_732, 0), _fx_catch_183);
            FX_COPY_PTR(v_732.t0, &subarr_exp_0);
            _fx_R9Ast__id_t v_765;
            fx_str_t slit_164 = FX_MAKE_STR("fx_flatten_arr");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_164, &v_765, 0), _fx_catch_183);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_5, &v_733, 0), _fx_catch_183);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(subarr_exp_0, &v_734, 0), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_734, 0, true, &v_735), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_733, v_735, false, &v_735), _fx_catch_183);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_765,
                  v_735, _fx_g20C_gen_code__CTypCInt, &kloc_0, &call_flatten_0, 0), _fx_catch_183);
            FX_CALL(
               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  call_flatten_0, ccode_121, &kloc_0, block_stack_ref_0, &v_736, 0), _fx_catch_183);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, subarr_exp_0, v_736, &v_1);
         }
         else if (need_subarr_0) {
            if (border_0->tag != 1) {
               fx_str_t slit_165 = FX_MAKE_STR("cgen: border extrapolation with ranges is not supported yet");
               FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_165, &v_737, 0), _fx_catch_183);
               FX_THROW(&v_737, false, _fx_catch_183);
            }
            _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(0, ccode_121, &__fold_result___16);
            FX_COPY_PTR(idxs_1, &idxs_3);
            _fx_LN13K_form__dom_t lst_20 = idxs_3;
            for (; lst_20; lst_20 = lst_20->tl) {
               _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_766 = {0};
               _fx_LN14C_form__cexp_t range_data_1 = 0;
               _fx_LN15C_form__cstmt_t ccode_140 = 0;
               _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_767 = {0};
               _fx_N13K_form__dom_t* d_1 = &lst_20->hd;
               _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___16, &v_766);
               FX_COPY_PTR(v_766.t0, &range_data_1);
               FX_COPY_PTR(v_766.t1, &ccode_140);
               int tag_22 = d_1->tag;
               if (tag_22 == 1) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_768 = {0};
                  _fx_N14C_form__cexp_t i_exp_6 = 0;
                  _fx_LN15C_form__cstmt_t ccode_141 = 0;
                  _fx_N14C_form__cexp_t v_769 = 0;
                  _fx_LN14C_form__cexp_t v_770 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(&d_1->u.DomainElem, ccode_140, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                        fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_768, atom2cexp_0.fcv), _fx_catch_169);
                  FX_COPY_PTR(v_768.t0, &i_exp_6);
                  FX_COPY_PTR(v_768.t1, &ccode_141);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_769, 0), _fx_catch_169);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_769, range_data_1, true, &v_770), _fx_catch_169);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_6, v_770, false, &v_770), _fx_catch_169);
                  _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(v_770, ccode_141, &v_767);

               _fx_catch_169: ;
                  if (v_770) {
                     _fx_free_LN14C_form__cexp_t(&v_770);
                  }
                  if (v_769) {
                     _fx_free_N14C_form__cexp_t(&v_769);
                  }
                  if (ccode_141) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_141);
                  }
                  if (i_exp_6) {
                     _fx_free_N14C_form__cexp_t(&i_exp_6);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_768);
               }
               else if (tag_22 == 2) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_771 = {0};
                  _fx_N14C_form__cexp_t i_exp_7 = 0;
                  _fx_LN15C_form__cstmt_t ccode_142 = 0;
                  _fx_N14C_form__cexp_t v_772 = 0;
                  _fx_LN14C_form__cexp_t v_773 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(&d_1->u.DomainFast, ccode_140, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                        fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_771, atom2cexp_0.fcv), _fx_catch_170);
                  FX_COPY_PTR(v_771.t0, &i_exp_7);
                  FX_COPY_PTR(v_771.t1, &ccode_142);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_772, 0), _fx_catch_170);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_772, range_data_1, true, &v_773), _fx_catch_170);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_7, v_773, false, &v_773), _fx_catch_170);
                  _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(v_773, ccode_142, &v_767);

               _fx_catch_170: ;
                  if (v_773) {
                     _fx_free_LN14C_form__cexp_t(&v_773);
                  }
                  if (v_772) {
                     _fx_free_N14C_form__cexp_t(&v_772);
                  }
                  if (ccode_142) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_142);
                  }
                  if (i_exp_7) {
                     _fx_free_N14C_form__cexp_t(&i_exp_7);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_771);
               }
               else if (tag_22 == 3) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_774 = {0};
                  _fx_N14C_form__cexp_t a_exp_3 = 0;
                  _fx_LN15C_form__cstmt_t ccode_143 = 0;
                  _fx_T2LN14C_form__cexp_tLN15C_form__cstmt_t v_775 = {0};
                  _fx_LN14C_form__cexp_t range_delta_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_144 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_776 = {0};
                  _fx_N14C_form__cexp_t d_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_145 = 0;
                  _fx_LN14C_form__cexp_t v_777 = 0;
                  _fx_LN14C_form__cexp_t v_778 = 0;
                  _fx_Ta3N14K_form__atom_t* vcase_17 = &d_1->u.DomainRange;
                  _fx_N14K_form__atom_t* b_2 = &vcase_17->t1;
                  _fx_N14K_form__atom_t* a_10 = &vcase_17->t0;
                  if (a_10->tag == 2) {
                     if (a_10->u.AtomLit.tag == 8) {
                        _fx_N14C_form__cexp_t v_779 = 0;
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_779, 0),
                           _fx_catch_171);
                        _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_779, ccode_140, &v_774);

                     _fx_catch_171: ;
                        if (v_779) {
                           _fx_free_N14C_form__cexp_t(&v_779);
                        }
                        goto _fx_endmatch_27;
                     }
                  }
                  FX_CALL(
                     atom2cexp_0.fp(a_10, ccode_140, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_774, atom2cexp_0.fcv), _fx_catch_172);

               _fx_catch_172: ;

               _fx_endmatch_27: ;
                  FX_CHECK_EXN(_fx_catch_175);
                  FX_COPY_PTR(v_774.t0, &a_exp_3);
                  FX_COPY_PTR(v_774.t1, &ccode_143);
                  if (b_2->tag == 2) {
                     if (b_2->u.AtomLit.tag == 8) {
                        _fx_N14C_form__cexp_t v_780 = 0;
                        _fx_LN14C_form__cexp_t v_781 = 0;
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(2, &kloc_0, &v_780, 0),
                           _fx_catch_173);
                        FX_CALL(_fx_cons_LN14C_form__cexp_t(v_780, 0, true, &v_781), _fx_catch_173);
                        FX_CALL(_fx_cons_LN14C_form__cexp_t(a_exp_3, v_781, false, &v_781), _fx_catch_173);
                        _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(v_781, ccode_143, &v_775);

                     _fx_catch_173: ;
                        if (v_781) {
                           _fx_free_LN14C_form__cexp_t(&v_781);
                        }
                        if (v_780) {
                           _fx_free_N14C_form__cexp_t(&v_780);
                        }
                        goto _fx_endmatch_28;
                     }
                  }
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_782 = {0};
                  _fx_N14C_form__cexp_t b_exp_3 = 0;
                  _fx_LN15C_form__cstmt_t ccode_146 = 0;
                  _fx_N14C_form__cexp_t v_783 = 0;
                  _fx_LN14C_form__cexp_t v_784 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(b_2, ccode_143, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
                        km_idx_0, &v_782, atom2cexp_0.fcv), _fx_catch_174);
                  FX_COPY_PTR(v_782.t0, &b_exp_3);
                  FX_COPY_PTR(v_782.t1, &ccode_146);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(1, &kloc_0, &v_783, 0), _fx_catch_174);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_783, 0, true, &v_784), _fx_catch_174);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(a_exp_3, v_784, false, &v_784), _fx_catch_174);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(b_exp_3, v_784, false, &v_784), _fx_catch_174);
                  _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(v_784, ccode_146, &v_775);

               _fx_catch_174: ;
                  if (v_784) {
                     _fx_free_LN14C_form__cexp_t(&v_784);
                  }
                  if (v_783) {
                     _fx_free_N14C_form__cexp_t(&v_783);
                  }
                  if (ccode_146) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_146);
                  }
                  if (b_exp_3) {
                     _fx_free_N14C_form__cexp_t(&b_exp_3);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_782);

               _fx_endmatch_28: ;
                  FX_CHECK_EXN(_fx_catch_175);
                  FX_COPY_PTR(v_775.t0, &range_delta_0);
                  FX_COPY_PTR(v_775.t1, &ccode_144);
                  FX_CALL(
                     atom2cexp_0.fp(&vcase_17->t2, ccode_144, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0,
                        i2e_ref_0, km_idx_0, &v_776, atom2cexp_0.fcv), _fx_catch_175);
                  FX_COPY_PTR(v_776.t0, &d_exp_0);
                  FX_COPY_PTR(v_776.t1, &ccode_145);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(d_exp_0, range_delta_0, true, &v_777), _fx_catch_175);
                  FX_CALL(
                     _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(v_777, range_data_1,
                        &v_778, 0), _fx_catch_175);
                  _fx_make_T2LN14C_form__cexp_tLN15C_form__cstmt_t(v_778, ccode_145, &v_767);

               _fx_catch_175: ;
                  if (v_778) {
                     _fx_free_LN14C_form__cexp_t(&v_778);
                  }
                  if (v_777) {
                     _fx_free_LN14C_form__cexp_t(&v_777);
                  }
                  if (ccode_145) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_145);
                  }
                  if (d_exp_0) {
                     _fx_free_N14C_form__cexp_t(&d_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_776);
                  if (ccode_144) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_144);
                  }
                  if (range_delta_0) {
                     _fx_free_LN14C_form__cexp_t(&range_delta_0);
                  }
                  _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_775);
                  if (ccode_143) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_143);
                  }
                  if (a_exp_3) {
                     _fx_free_N14C_form__cexp_t(&a_exp_3);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_774);
               }
               else {
                  FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_176);
               }
               FX_CHECK_EXN(_fx_catch_176);
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___16);
               _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_767, &__fold_result___16);

            _fx_catch_176: ;
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_767);
               if (ccode_140) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_140);
               }
               if (range_data_1) {
                  _fx_free_LN14C_form__cexp_t(&range_data_1);
               }
               _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_766);
               FX_CHECK_EXN(_fx_catch_183);
            }
            _fx_copy_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___16, &v_738);
            FX_COPY_PTR(v_738.t0, &range_data_0);
            FX_COPY_PTR(v_738.t1, &ccode_135);
            fx_str_t slit_166 = FX_MAKE_STR("arr");
            FX_CALL(
               _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                  dstexp_r_0, &slit_166, ctyp_0, ccode_135, &kloc_0, block_stack_ref_0, km_idx_0, &v_739, 0), _fx_catch_183);
            FX_COPY_PTR(v_739.t0, &subarr_exp_1);
            FX_COPY_PTR(v_739.t1, &ccode_136);
            FX_CALL(_fx_cons_LN19C_form__ctyp_attr_t(&_fx_g21C_gen_code__CTypConst, 0, true, &v_740), _fx_catch_183);
            FX_CALL(
               _fx_M6C_formFM12CTypRawArrayN14C_form__ctyp_t2LN19C_form__ctyp_attr_tN14C_form__ctyp_t(v_740,
                  _fx_g19C_gen_code__CTypInt, &rdata_ctyp_0), _fx_catch_183);
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(range_data_0, &v_741, 0), _fx_catch_183);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(rdata_ctyp_0, &kloc_0, &v_742);
            FX_CALL(
               _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(v_741, &v_742,
                  &rdata_arr_0), _fx_catch_183);
            _fx_R9Ast__id_t v_785;
            fx_str_t slit_167 = FX_MAKE_STR("ranges");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_167, &v_785, 0), _fx_catch_183);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_743, 0), _fx_catch_183);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(rdata_arr_0, &v_744);
            fx_str_t slit_168 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_785, rdata_ctyp_0, &v_743, &slit_168, &v_744, 0, &kloc_0, &v_745, 0), _fx_catch_183);
            FX_COPY_PTR(v_745.t0, &rdata_exp_0);
            FX_COPY_PTR(v_745.t1, &sub_ccode_10);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(arr_exp_5, &v_746, 0), _fx_catch_183);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(subarr_exp_1, &v_747, 0), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_747, 0, true, &v_748), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(rdata_exp_0, v_748, false, &v_748), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_746, v_748, false, &v_748), _fx_catch_183);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g21C_form__std_fx_subarr, v_748, _fx_g19C_gen_code__CTypInt, &kloc_0, &call_subarr_0, 0), _fx_catch_183);
            FX_CALL(
               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  call_subarr_0, sub_ccode_10, &kloc_0, block_stack_ref_0, &sub_ccode_11, 0), _fx_catch_183);
            FX_CALL(
               _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(sub_ccode_11, &kloc_0, &v_749, 0),
               _fx_catch_183);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_749, ccode_136, true, &ccode_137), _fx_catch_183);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, subarr_exp_1, ccode_137, &v_1);
         }
         else {
            _fx_make_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&_fx_g18C_gen_code__None2_, 0,
               ccode_121, &__fold_result___17);
            int_ dim_0 = 0;
            FX_COPY_PTR(idxs_1, &idxs_4);
            _fx_LN13K_form__dom_t lst_21 = idxs_4;
            for (; lst_21; lst_21 = lst_21->tl, dim_0 += 1) {
               _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_786 = {0};
               _fx_Nt6option1N14C_form__cexp_t chk_exp_opt_1 = {0};
               _fx_LN14C_form__cexp_t i_exps_4 = 0;
               _fx_LN15C_form__cstmt_t ccode_147 = 0;
               _fx_N13K_form__dom_t d_2 = {0};
               _fx_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t v_787 = {0};
               _fx_N13K_form__dom_t* d_3 = &lst_21->hd;
               _fx_copy_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___17, &v_786);
               _fx_copy_Nt6option1N14C_form__cexp_t(&v_786.t0, &chk_exp_opt_1);
               FX_COPY_PTR(v_786.t1, &i_exps_4);
               FX_COPY_PTR(v_786.t2, &ccode_147);
               if (border_0->tag == 1) {
                  _fx_copy_N13K_form__dom_t(d_3, &d_2);
               }
               else {
                  if (d_3->tag == 1) {
                     _fx_M6K_formFM10DomainFastN13K_form__dom_t1N14K_form__atom_t(&d_3->u.DomainElem, &d_2);
                  }
                  else {
                     _fx_copy_N13K_form__dom_t(d_3, &d_2);
                  }
                  FX_CHECK_EXN(_fx_catch_181);
               }
               int tag_23 = d_2.tag;
               if (tag_23 == 2) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_788 = {0};
                  _fx_N14C_form__cexp_t i_exp_8 = 0;
                  _fx_LN15C_form__cstmt_t ccode_148 = 0;
                  _fx_LN14C_form__cexp_t v_789 = 0;
                  FX_CALL(
                     atom2cexp_0.fp(&d_2.u.DomainFast, ccode_147, &kloc_0, block_stack_ref_0, defined_syms_ref_0,
                        fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_788, atom2cexp_0.fcv), _fx_catch_177);
                  FX_COPY_PTR(v_788.t0, &i_exp_8);
                  FX_COPY_PTR(v_788.t1, &ccode_148);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_8, i_exps_4, true, &v_789), _fx_catch_177);
                  _fx_make_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&chk_exp_opt_1, v_789, ccode_148,
                     &v_787);

               _fx_catch_177: ;
                  if (v_789) {
                     _fx_free_LN14C_form__cexp_t(&v_789);
                  }
                  if (ccode_148) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_148);
                  }
                  if (i_exp_8) {
                     _fx_free_N14C_form__cexp_t(&i_exp_8);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_788);
               }
               else if (tag_23 == 1) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_790 = {0};
                  _fx_N14C_form__cexp_t i_exp_9 = 0;
                  _fx_LN15C_form__cstmt_t ccode_149 = 0;
                  _fx_N14C_form__cexp_t v_791 = 0;
                  _fx_LN14C_form__cexp_t v_792 = 0;
                  _fx_N14C_form__cexp_t chk_exp1_0 = 0;
                  _fx_Nt6option1N14C_form__cexp_t chk_exp_opt_2 = {0};
                  _fx_LN14C_form__cexp_t v_793 = 0;
                  FX_CALL(atom2cexp__0.fp(&d_2.u.DomainElem, true, ccode_147, &kloc_0, &v_790, atom2cexp__0.fcv),
                     _fx_catch_179);
                  FX_COPY_PTR(v_790.t0, &i_exp_9);
                  FX_COPY_PTR(v_790.t1, &ccode_149);
                  FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(dim_0, &kloc_0, &v_791, 0),
                     _fx_catch_179);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_9, 0, true, &v_792), _fx_catch_179);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_791, v_792, false, &v_792), _fx_catch_179);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_792, false, &v_792), _fx_catch_179);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &_fx_g22C_form__std_FX_CHKIDX1, v_792, _fx_g20C_gen_code__CTypBool, &kloc_0, &chk_exp1_0, 0),
                     _fx_catch_179);
                  if (chk_exp_opt_1.tag == 2) {
                     _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_794 = {0};
                     _fx_N14C_form__cexp_t chk_exp_2 = 0;
                     _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &kloc_0, &v_794);
                     FX_CALL(
                        _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g23C_gen_code__COpLogicAnd, chk_exp_opt_1.u.Some, chk_exp1_0, &v_794, &chk_exp_2),
                        _fx_catch_178);
                     _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(chk_exp_2, &chk_exp_opt_2);

                  _fx_catch_178: ;
                     if (chk_exp_2) {
                        _fx_free_N14C_form__cexp_t(&chk_exp_2);
                     }
                     _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_794);
                  }
                  else {
                     _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(chk_exp1_0, &chk_exp_opt_2);
                  }
                  FX_CHECK_EXN(_fx_catch_179);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_9, i_exps_4, true, &v_793), _fx_catch_179);
                  _fx_make_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&chk_exp_opt_2, v_793, ccode_149,
                     &v_787);

               _fx_catch_179: ;
                  if (v_793) {
                     _fx_free_LN14C_form__cexp_t(&v_793);
                  }
                  _fx_free_Nt6option1N14C_form__cexp_t(&chk_exp_opt_2);
                  if (chk_exp1_0) {
                     _fx_free_N14C_form__cexp_t(&chk_exp1_0);
                  }
                  if (v_792) {
                     _fx_free_LN14C_form__cexp_t(&v_792);
                  }
                  if (v_791) {
                     _fx_free_N14C_form__cexp_t(&v_791);
                  }
                  if (ccode_149) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_149);
                  }
                  if (i_exp_9) {
                     _fx_free_N14C_form__cexp_t(&i_exp_9);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_790);
               }
               else {
                  fx_exn_t v_795 = {0};
                  fx_str_t slit_169 = FX_MAKE_STR("cgen: unexpected index type");
                  FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_169, &v_795, 0), _fx_catch_180);
                  FX_THROW(&v_795, false, _fx_catch_180);

               _fx_catch_180: ;
                  fx_free_exn(&v_795);
               }
               FX_CHECK_EXN(_fx_catch_181);
               _fx_free_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___17);
               _fx_copy_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_787, &__fold_result___17);

            _fx_catch_181: ;
               _fx_free_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_787);
               _fx_free_N13K_form__dom_t(&d_2);
               if (ccode_147) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_147);
               }
               if (i_exps_4) {
                  _fx_free_LN14C_form__cexp_t(&i_exps_4);
               }
               _fx_free_Nt6option1N14C_form__cexp_t(&chk_exp_opt_1);
               _fx_free_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_786);
               FX_CHECK_EXN(_fx_catch_183);
            }
            _fx_copy_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___17, &v_750);
            _fx_copy_Nt6option1N14C_form__cexp_t(&v_750.t0, &chk_exp_opt_0);
            FX_COPY_PTR(v_750.t1, &i_exps_3);
            FX_COPY_PTR(v_750.t2, &ccode_138);
            if (chk_exp_opt_0.tag == 2) {
               _fx_LN14C_form__cexp_t v_796 = 0;
               _fx_N14C_form__cexp_t call_chkidx_0 = 0;
               _fx_N15C_form__cstmt_t v_797 = 0;
               FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_5, 0, true, &v_796), _fx_catch_182);
               FX_CALL(_fx_cons_LN14C_form__cexp_t(chk_exp_opt_0.u.Some, v_796, false, &v_796), _fx_catch_182);
               FX_CALL(
                  _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                     &_fx_g21C_form__std_FX_CHKIDX, v_796, _fx_g20C_gen_code__CTypVoid, &kloc_0, &call_chkidx_0, 0),
                  _fx_catch_182);
               FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_chkidx_0, &v_797), _fx_catch_182);
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_797, ccode_138, true, &ccode_139), _fx_catch_182);

            _fx_catch_182: ;
               if (v_797) {
                  _fx_free_N15C_form__cstmt_t(&v_797);
               }
               if (call_chkidx_0) {
                  _fx_free_N14C_form__cexp_t(&call_chkidx_0);
               }
               if (v_796) {
                  _fx_free_LN14C_form__cexp_t(&v_796);
               }
            }
            else {
               FX_COPY_PTR(ccode_138, &ccode_139);
            }
            FX_CHECK_EXN(_fx_catch_183);
            int_ ndims_2;
            FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN13K_form__dom_t(idxs_1, &ndims_2, 0), _fx_catch_183);
            int tag_24 = border_0->tag;
            if (tag_24 == 1) {
               FX_COPY_PTR(_fx_g21C_form__std_FX_PTR_xD, &access_op_0);
            }
            else if (tag_24 == 2) {
               FX_COPY_PTR(_fx_g26C_form__std_FX_PTR_xD_CLIP, &access_op_0);
            }
            else if (tag_24 == 3) {
               FX_COPY_PTR(_fx_g26C_form__std_FX_PTR_xD_WRAP, &access_op_0);
            }
            else if (tag_24 == 4) {
               FX_COPY_PTR(_fx_g26C_form__std_FX_PTR_xD_ZERO, &access_op_0);
            }
            else {
               FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_183);
            }
            FX_CHECK_EXN(_fx_catch_183);
            _fx_R9Ast__id_t v_798;
            FX_CALL(_fx_M10C_gen_codeFM3nthR9Ast__id_t2LR9Ast__id_ti(access_op_0, ndims_2 - 1, &v_798, 0), _fx_catch_183);
            FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_751),
               _fx_catch_183);
            FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(i_exps_3, &v_752, 0), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(arr_exp_5, v_752, true, &v_753), _fx_catch_183);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_751, v_753, false, &v_753), _fx_catch_183);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(ctyp_0, &v_754, 0), _fx_catch_183);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_798,
                  v_753, v_754, &kloc_0, &get_elem_exp_9, 0), _fx_catch_183);
            FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(get_elem_exp_9, &v_755, 0), _fx_catch_183);
            _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_755, ccode_139, &v_1);
         }

      _fx_catch_183: ;
         if (v_755) {
            _fx_free_N14C_form__cexp_t(&v_755);
         }
         if (get_elem_exp_9) {
            _fx_free_N14C_form__cexp_t(&get_elem_exp_9);
         }
         if (v_754) {
            _fx_free_N14C_form__ctyp_t(&v_754);
         }
         if (v_753) {
            _fx_free_LN14C_form__cexp_t(&v_753);
         }
         if (v_752) {
            _fx_free_LN14C_form__cexp_t(&v_752);
         }
         if (v_751) {
            _fx_free_N14C_form__cexp_t(&v_751);
         }
         FX_FREE_LIST_SIMPLE(&access_op_0);
         if (ccode_139) {
            _fx_free_LN15C_form__cstmt_t(&ccode_139);
         }
         if (ccode_138) {
            _fx_free_LN15C_form__cstmt_t(&ccode_138);
         }
         if (i_exps_3) {
            _fx_free_LN14C_form__cexp_t(&i_exps_3);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&chk_exp_opt_0);
         _fx_free_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&v_750);
         if (idxs_4) {
            _fx_free_LN13K_form__dom_t(&idxs_4);
         }
         _fx_free_T3Nt6option1N14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___17);
         if (ccode_137) {
            _fx_free_LN15C_form__cstmt_t(&ccode_137);
         }
         if (v_749) {
            _fx_free_N15C_form__cstmt_t(&v_749);
         }
         if (sub_ccode_11) {
            _fx_free_LN15C_form__cstmt_t(&sub_ccode_11);
         }
         if (call_subarr_0) {
            _fx_free_N14C_form__cexp_t(&call_subarr_0);
         }
         if (v_748) {
            _fx_free_LN14C_form__cexp_t(&v_748);
         }
         if (v_747) {
            _fx_free_N14C_form__cexp_t(&v_747);
         }
         if (v_746) {
            _fx_free_N14C_form__cexp_t(&v_746);
         }
         if (sub_ccode_10) {
            _fx_free_LN15C_form__cstmt_t(&sub_ccode_10);
         }
         if (rdata_exp_0) {
            _fx_free_N14C_form__cexp_t(&rdata_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_745);
         _fx_free_Nt6option1N14C_form__cexp_t(&v_744);
         _fx_free_R16Ast__val_flags_t(&v_743);
         if (rdata_arr_0) {
            _fx_free_N14C_form__cexp_t(&rdata_arr_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_742);
         if (v_741) {
            _fx_free_LN14C_form__cexp_t(&v_741);
         }
         if (rdata_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&rdata_ctyp_0);
         }
         FX_FREE_LIST_SIMPLE(&v_740);
         if (ccode_136) {
            _fx_free_LN15C_form__cstmt_t(&ccode_136);
         }
         if (subarr_exp_1) {
            _fx_free_N14C_form__cexp_t(&subarr_exp_1);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_739);
         if (ccode_135) {
            _fx_free_LN15C_form__cstmt_t(&ccode_135);
         }
         if (range_data_0) {
            _fx_free_LN14C_form__cexp_t(&range_data_0);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&v_738);
         if (idxs_3) {
            _fx_free_LN13K_form__dom_t(&idxs_3);
         }
         _fx_free_T2LN14C_form__cexp_tLN15C_form__cstmt_t(&__fold_result___16);
         fx_free_exn(&v_737);
         if (v_736) {
            _fx_free_LN15C_form__cstmt_t(&v_736);
         }
         if (call_flatten_0) {
            _fx_free_N14C_form__cexp_t(&call_flatten_0);
         }
         if (v_735) {
            _fx_free_LN14C_form__cexp_t(&v_735);
         }
         if (v_734) {
            _fx_free_N14C_form__cexp_t(&v_734);
         }
         if (v_733) {
            _fx_free_N14C_form__cexp_t(&v_733);
         }
         if (subarr_exp_0) {
            _fx_free_N14C_form__cexp_t(&subarr_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_732);
         if (idxs_2) {
            _fx_free_LN13K_form__dom_t(&idxs_2);
         }
      }
      else {
         fx_exn_t v_799 = {0};
         fx_str_t slit_170 =
            FX_MAKE_STR(
               "cgen: unknown/unsupported type of the container, it should be CTypArray _ or CTypVector _ or CTypString");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_170, &v_799, 0), _fx_catch_184);
         FX_THROW(&v_799, false, _fx_catch_184);

      _fx_catch_184: ;
         fx_free_exn(&v_799);
      }
      FX_CHECK_EXN(_fx_catch_185);

   _fx_catch_185: ;
      if (arr_ctyp_0) {
         _fx_free_N14C_form__ctyp_t(&arr_ctyp_0);
      }
      if (lbl_5) {
         _fx_free_N14C_form__cexp_t(&lbl_5);
      }
      if (ccode_121) {
         _fx_free_LN15C_form__cstmt_t(&ccode_121);
      }
      if (arr_exp_5) {
         _fx_free_N14C_form__cexp_t(&arr_exp_5);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_646);
      fx_free_exn(&v_645);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 20) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_800 = {0};
      _fx_N14C_form__cexp_t ce1_7 = 0;
      _fx_LN15C_form__cstmt_t ccode_150 = 0;
      _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti v_801 = {0};
      _fx_N14C_form__cexp_t ce1_8 = 0;
      _fx_LT2R9Ast__id_tN14C_form__ctyp_t relems_0 = 0;
      fx_str_t v_802 = {0};
      fx_str_t v_803 = {0};
      fx_str_t v_804 = {0};
      fx_exn_t v_805 = {0};
      _fx_T2R9Ast__id_tN14C_form__ctyp_t v_806 = {0};
      _fx_N14C_form__cexp_t v_807 = 0;
      _fx_T3R9Ast__id_tiT2N14K_form__ktyp_tR10Ast__loc_t* vcase_18 = &kexp_0->u.KExpMem;
      int_ n_1 = vcase_18->t1;
      FX_CALL(
         _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
            &vcase_18->t0, false, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
            km_idx_0, &v_800, 0), _fx_catch_186);
      FX_COPY_PTR(v_800.t0, &ce1_7);
      FX_COPY_PTR(v_800.t1, &ccode_150);
      FX_CALL(
         _fx_M10C_gen_codeFM10get_structT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti1N14C_form__cexp_t(ce1_7,
            &v_801, 0), _fx_catch_186);
      FX_COPY_PTR(v_801.t1, &ce1_8);
      FX_COPY_PTR(v_801.t2, &relems_0);
      int_ ofs_0 = v_801.t3;
      int_ nelems_0;
      FX_CALL(_fx_M10C_gen_codeFM8length1_i1LT2R9Ast__id_tN14C_form__ctyp_t(relems_0, &nelems_0, 0), _fx_catch_186);
      bool t_11;
      if (n_1 < 0) {
         t_11 = true;
      }
      else {
         t_11 = n_1 + ofs_0 >= nelems_0;
      }
      if (t_11) {
         FX_CALL(_fx_F6stringS1i(n_1, &v_802, 0), _fx_catch_186);
         FX_CALL(_fx_F6stringS1i(nelems_0, &v_803, 0), _fx_catch_186);
         fx_str_t slit_171 = FX_MAKE_STR("cgen: the tuple/record element index ");
         fx_str_t slit_172 = FX_MAKE_STR(" is out of range [0, ");
         fx_str_t slit_173 = FX_MAKE_STR("]");
         {
            const fx_str_t strs_31[] = { slit_171, v_802, slit_172, v_803, slit_173 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_31, 5, &v_804), _fx_catch_186);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_804, &v_805, 0), _fx_catch_186);
         FX_THROW(&v_805, false, _fx_catch_186);
      }
      FX_CALL(
         _fx_M10C_gen_codeFM3nthT2R9Ast__id_tN14C_form__ctyp_t2LT2R9Ast__id_tN14C_form__ctyp_ti(relems_0, n_1 + ofs_0, &v_806,
            0), _fx_catch_186);
      _fx_R9Ast__id_t n_id_1 = v_806.t0;
      FX_CALL(
         _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(ce1_8, &n_id_1, ctyp_0, &v_807,
            0), _fx_catch_186);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_807, ccode_150, &v_1);

   _fx_catch_186: ;
      if (v_807) {
         _fx_free_N14C_form__cexp_t(&v_807);
      }
      _fx_free_T2R9Ast__id_tN14C_form__ctyp_t(&v_806);
      fx_free_exn(&v_805);
      FX_FREE_STR(&v_804);
      FX_FREE_STR(&v_803);
      FX_FREE_STR(&v_802);
      if (relems_0) {
         _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&relems_0);
      }
      if (ce1_8) {
         _fx_free_N14C_form__cexp_t(&ce1_8);
      }
      _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&v_801);
      if (ccode_150) {
         _fx_free_LN15C_form__cstmt_t(&ccode_150);
      }
      if (ce1_7) {
         _fx_free_N14C_form__cexp_t(&ce1_7);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_800);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 21) {
      _fx_N14K_form__ktyp_t ktyp_2 = 0;
      _fx_LN15C_form__cstmt_t ccode_151 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_808 = {0};
      _fx_N14C_form__cexp_t i_exp_10 = 0;
      _fx_LN15C_form__cstmt_t ccode_152 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_809 = {0};
      _fx_N14C_form__cexp_t e_exp_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_153 = 0;
      _fx_N14C_form__ctyp_t ctyp_2 = 0;
      _fx_N14C_form__cexp_t v_810 = 0;
      _fx_N14C_form__cexp_t v_811 = 0;
      _fx_N14C_form__cexp_t v_812 = 0;
      _fx_LN14C_form__cexp_t v_813 = 0;
      _fx_N14C_form__cexp_t copy_arr_data_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_154 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_814 = {0};
      _fx_N14C_form__cexp_t i_exp_11 = 0;
      _fx_LN15C_form__cstmt_t ccode_155 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_815 = {0};
      _fx_N14C_form__cexp_t a_exp_4 = 0;
      _fx_LN15C_form__cstmt_t ccode_156 = 0;
      _fx_T3R9Ast__id_tN14K_form__atom_tR10Ast__loc_t* vcase_19 = &kexp_0->u.KExpAssign;
      _fx_N14K_form__atom_t* a_11 = &vcase_19->t1;
      _fx_R9Ast__id_t* i_6 = &vcase_19->t0;
      FX_CALL(_fx_M6K_formFM12get_idk_ktypN14K_form__ktyp_t2R9Ast__id_tR10Ast__loc_t(i_6, &kloc_0, &ktyp_2, 0), _fx_catch_187);
      _fx_R17K_form__ktprops_t v_816;
      FX_CALL(_fx_M10K_annotateFM11get_ktpropsR17K_form__ktprops_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_2, &kloc_0, &v_816, 0),
         _fx_catch_187);
      bool ktp_complex_0 = v_816.ktp_complex;
      if (ktp_complex_0) {
         FX_CALL(
            _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
               i_6, true, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
               &v_808, 0), _fx_catch_187);
         FX_COPY_PTR(v_808.t0, &i_exp_10);
         FX_COPY_PTR(v_808.t1, &ccode_152);
         FX_CALL(atom2cexp__0.fp(a_11, true, ccode_152, &kloc_0, &v_809, atom2cexp__0.fcv), _fx_catch_187);
         FX_COPY_PTR(v_809.t0, &e_exp_0);
         FX_COPY_PTR(v_809.t1, &ccode_153);
         FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(i_exp_10, &ctyp_2, 0), _fx_catch_187);
         bool v_817;
         FX_CALL(_fx_M6K_formFM11is_subarrayB2R9Ast__id_tR10Ast__loc_t(i_6, &kloc_0, &v_817, 0), _fx_catch_187);
         if (v_817) {
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(e_exp_0, &v_810, 0), _fx_catch_187);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(i_exp_10, &v_811, 0), _fx_catch_187);
            FX_CALL(_fx_M6C_formFM13make_bool_expN14C_form__cexp_t2BR10Ast__loc_t(true, &kloc_0, &v_812, 0), _fx_catch_187);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_812, 0, true, &v_813), _fx_catch_187);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_811, v_813, false, &v_813), _fx_catch_187);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_810, v_813, false, &v_813), _fx_catch_187);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g28C_form__std_fx_copy_arr_data, v_813, _fx_g19C_gen_code__CTypInt, &kloc_0, &copy_arr_data_0, 0),
               _fx_catch_187);
            FX_CALL(
               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  copy_arr_data_0, ccode_153, &kloc_0, block_stack_ref_0, &ccode_151, 0), _fx_catch_187);
         }
         else {
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_free_codeLN15C_form__cstmt_t6N14C_form__cexp_tN14C_form__ctyp_tBBLN15C_form__cstmt_tR10Ast__loc_t(
                  i_exp_10, ctyp_2, true, false, ccode_153, &kloc_0, &ccode_154, 0), _fx_catch_187);
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  e_exp_0, i_exp_10, ctyp_2, ccode_154, &kloc_0, &ccode_151, 0), _fx_catch_187);
         }
      }
      else {
         FX_CALL(
            _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
               i_6, false, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
               &v_814, 0), _fx_catch_187);
         FX_COPY_PTR(v_814.t0, &i_exp_11);
         FX_COPY_PTR(v_814.t1, &ccode_155);
         FX_CALL(
            atom2cexp_0.fp(a_11, ccode_155, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0,
               km_idx_0, &v_815, atom2cexp_0.fcv), _fx_catch_187);
         FX_COPY_PTR(v_815.t0, &a_exp_4);
         FX_COPY_PTR(v_815.t1, &ccode_156);
         FX_CALL(
            _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
               a_exp_4, i_exp_11, ctyp_0, ccode_156, &kloc_0, &ccode_151, 0), _fx_catch_187);
      }
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_151, &v_1);

   _fx_catch_187: ;
      if (ccode_156) {
         _fx_free_LN15C_form__cstmt_t(&ccode_156);
      }
      if (a_exp_4) {
         _fx_free_N14C_form__cexp_t(&a_exp_4);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_815);
      if (ccode_155) {
         _fx_free_LN15C_form__cstmt_t(&ccode_155);
      }
      if (i_exp_11) {
         _fx_free_N14C_form__cexp_t(&i_exp_11);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_814);
      if (ccode_154) {
         _fx_free_LN15C_form__cstmt_t(&ccode_154);
      }
      if (copy_arr_data_0) {
         _fx_free_N14C_form__cexp_t(&copy_arr_data_0);
      }
      if (v_813) {
         _fx_free_LN14C_form__cexp_t(&v_813);
      }
      if (v_812) {
         _fx_free_N14C_form__cexp_t(&v_812);
      }
      if (v_811) {
         _fx_free_N14C_form__cexp_t(&v_811);
      }
      if (v_810) {
         _fx_free_N14C_form__cexp_t(&v_810);
      }
      if (ctyp_2) {
         _fx_free_N14C_form__ctyp_t(&ctyp_2);
      }
      if (ccode_153) {
         _fx_free_LN15C_form__cstmt_t(&ccode_153);
      }
      if (e_exp_0) {
         _fx_free_N14C_form__cexp_t(&e_exp_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_809);
      if (ccode_152) {
         _fx_free_LN15C_form__cstmt_t(&ccode_152);
      }
      if (i_exp_10) {
         _fx_free_N14C_form__cexp_t(&i_exp_10);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_808);
      if (ccode_151) {
         _fx_free_LN15C_form__cstmt_t(&ccode_151);
      }
      if (ktyp_2) {
         _fx_free_N14K_form__ktyp_t(&ktyp_2);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 22) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_818 = {0};
      _fx_N14C_form__cexp_t dst_exp_13 = 0;
      _fx_LN15C_form__cstmt_t ccode_157 = 0;
      _fx_LN15C_form__cstmt_t ccode_158 = 0;
      fx_str_t slit_174 = FX_MAKE_STR("res");
      FX_CALL(
         _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
            dstexp_r_0, &slit_174, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_818, 0), _fx_catch_188);
      FX_COPY_PTR(v_818.t0, &dst_exp_13);
      FX_COPY_PTR(v_818.t1, &ccode_157);
      FX_CALL(
         process_cases_0.fp(kexp_0->u.KExpMatch.t0, dstexp_r_0, ccode_157, false, &kloc_0, block_stack_ref_0,
            defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0,
            i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0, return_used_ref_0, top_inline_ccode_ref_0, u1vals_0,
            &ccode_158, process_cases_0.fcv), _fx_catch_188);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_13, ccode_158, &v_1);

   _fx_catch_188: ;
      if (ccode_158) {
         _fx_free_LN15C_form__cstmt_t(&ccode_158);
      }
      if (ccode_157) {
         _fx_free_LN15C_form__cstmt_t(&ccode_157);
      }
      if (dst_exp_13) {
         _fx_free_N14C_form__cexp_t(&dst_exp_13);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_818);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 23) {
      _fx_Ta2N14K_form__kexp_t v_819 = {0};
      _fx_N14K_form__kexp_t pop_exn_0 = 0;
      _fx_N14K_form__kexp_t catch_e_0 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_820 = {0};
      _fx_N14C_form__cexp_t dst_exp_14 = 0;
      _fx_LN15C_form__cstmt_t ccode_159 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_821 = {0};
      _fx_LN15C_form__cstmt_t try_ccode_0 = 0;
      _fx_rR23C_gen_code__block_ctx_t bctx_try_0 = 0;
      _fx_LN15C_form__cstmt_t bctx_cleanup_1 = 0;
      _fx_LN15C_form__cstmt_t bctx_prologue_1 = 0;
      _fx_LN15C_form__cstmt_t epilogue_1 = 0;
      _fx_N15C_form__cstmt_t v_822 = 0;
      _fx_LN15C_form__cstmt_t v_823 = 0;
      _fx_LN15C_form__cstmt_t v_824 = 0;
      _fx_LN15C_form__cstmt_t v_825 = 0;
      _fx_LN15C_form__cstmt_t ccode_160 = 0;
      _fx_N14C_form__cexp_t fx_status_exp_1 = 0;
      _fx_rNt6option1N14C_form__cexp_t v_826 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_827 = {0};
      _fx_LN15C_form__cstmt_t catch_ccode_0 = 0;
      _fx_N14C_form__cexp_t v_828 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_829 = {0};
      _fx_N14C_form__cexp_t v_830 = 0;
      _fx_N15C_form__cstmt_t v_831 = 0;
      _fx_LN15C_form__cstmt_t catch_ccode_1 = 0;
      _fx_LN15C_form__cstmt_t catch_ccode_2 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_832 = {0};
      _fx_LN15C_form__cstmt_t catch_ccode_3 = 0;
      _fx_N14C_form__cexp_t v_833 = 0;
      _fx_N14C_form__cexp_t v_834 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_835 = {0};
      _fx_N14C_form__cexp_t check_neg_status_0 = 0;
      _fx_N15C_form__cstmt_t v_836 = 0;
      _fx_N15C_form__cstmt_t v_837 = 0;
      _fx_N15C_form__cstmt_t catch_clause_0 = 0;
      _fx_LN15C_form__cstmt_t v_838 = 0;
      _fx_T3N14K_form__kexp_tN14K_form__kexp_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_20 = &kexp_0->u.KExpTryCatch;
      _fx_N14K_form__kexp_t catch_e_1 = vcase_20->t1;
      _fx_N14K_form__kexp_t try_e_0 = vcase_20->t0;
      int tag_25 = FX_REC_VARIANT_TAG(catch_e_1);
      if (tag_25 == 10) {
         _fx_LN14K_form__kexp_t v_839 = catch_e_1->u.KExpSeq.t0;
         if (v_839 != 0) {
            _fx_N14K_form__kexp_t pop_exn_1 = v_839->hd;
            if (FX_REC_VARIANT_TAG(pop_exn_1) == 31) {
               _fx_N14K_form__kexp_t v_840 = pop_exn_1->u.KDefVal.t1;
               if (FX_REC_VARIANT_TAG(v_840) == 8) {
                  if (v_840->u.KExpIntrin.t0.tag == 1) {
                     _fx_N14K_form__kexp_t v_841 = 0;
                     FX_CALL(
                        _fx_M6K_formFM9code2kexpN14K_form__kexp_t2LN14K_form__kexp_tR10Ast__loc_t(v_839->tl, &kloc_0, &v_841,
                           0), _fx_catch_189);
                     _fx_make_Ta2N14K_form__kexp_t(pop_exn_1, v_841, &v_819);

                  _fx_catch_189: ;
                     if (v_841) {
                        _fx_free_N14K_form__kexp_t(&v_841);
                     }
                     goto _fx_endmatch_29;
                  }
               }
            }
         }
      }
      if (tag_25 == 10) {
         _fx_LN14K_form__kexp_t v_842 = catch_e_1->u.KExpSeq.t0;
         if (v_842 != 0) {
            _fx_N14K_form__kexp_t pop_exn_2 = v_842->hd;
            if (FX_REC_VARIANT_TAG(pop_exn_2) == 8) {
               if (pop_exn_2->u.KExpIntrin.t0.tag == 1) {
                  _fx_N14K_form__kexp_t v_843 = 0;
                  FX_CALL(
                     _fx_M6K_formFM9code2kexpN14K_form__kexp_t2LN14K_form__kexp_tR10Ast__loc_t(v_842->tl, &kloc_0, &v_843, 0),
                     _fx_catch_190);
                  _fx_make_Ta2N14K_form__kexp_t(pop_exn_2, v_843, &v_819);

               _fx_catch_190: ;
                  if (v_843) {
                     _fx_free_N14K_form__kexp_t(&v_843);
                  }
                  goto _fx_endmatch_29;
               }
            }
         }
      }
      fx_exn_t v_844 = {0};
      fx_str_t slit_175 = FX_MAKE_STR("catch part in KExpTryCatch() should be a sequence starting with \'val x = pop_exn()\'");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_175, &v_844, 0), _fx_catch_191);
      FX_THROW(&v_844, false, _fx_catch_191);

   _fx_catch_191: ;
      fx_free_exn(&v_844);

   _fx_endmatch_29: ;
      FX_CHECK_EXN(_fx_catch_193);
      FX_COPY_PTR(v_819.t0, &pop_exn_0);
      FX_COPY_PTR(v_819.t1, &catch_e_0);
      fx_str_t slit_176 = FX_MAKE_STR("res");
      FX_CALL(
         _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
            dstexp_r_0, &slit_176, ctyp_0, ccode_0, &kloc_0, block_stack_ref_0, km_idx_0, &v_820, 0), _fx_catch_193);
      FX_COPY_PTR(v_820.t0, &dst_exp_14);
      FX_COPY_PTR(v_820.t1, &ccode_159);
      _fx_R10Ast__loc_t try_loc_0;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(try_e_0, &try_loc_0, 0), _fx_catch_193);
      _fx_R10Ast__loc_t try_end_loc_0;
      FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(&try_loc_0, &try_end_loc_0, 0), _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
            &_fx_g25C_gen_code__BlockKind_Try, &try_loc_0, block_stack_ref_0, km_idx_0, 0), _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            try_e_0, dstexp_r_0, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0,
            fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0, return_used_ref_0,
            top_inline_ccode_ref_0, u1vals_0, &v_821, fx_fv), _fx_catch_193);
      FX_COPY_PTR(v_821.t1, &try_ccode_0);
      FX_CALL(
         _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &bctx_try_0, 0), _fx_catch_193);
      _fx_R23C_gen_code__block_ctx_t* v_845 = &bctx_try_0->data;
      int_ bctx_label_used_1 = v_845->bctx_label_used;
      _fx_R9Ast__id_t bctx_label_1 = v_845->bctx_label;
      FX_COPY_PTR(v_845->bctx_cleanup, &bctx_cleanup_1);
      FX_COPY_PTR(v_845->bctx_prologue, &bctx_prologue_1);
      if (bctx_label_used_1 == 0) {
         FX_COPY_PTR(bctx_cleanup_1, &epilogue_1);
      }
      else {
         FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&bctx_label_1, &try_end_loc_0, &v_822),
            _fx_catch_193);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_822, 0, true, &v_823), _fx_catch_193);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(bctx_cleanup_1, v_823,
               &epilogue_1, 0), _fx_catch_193);
      }
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(bctx_prologue_1, ccode_159,
            &v_824, 0), _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(try_ccode_0, v_824, &v_825, 0),
         _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(epilogue_1, v_825, &ccode_160,
            0), _fx_catch_193);
      FX_CALL(_fx_M10C_gen_codeFM13pop_block_ctxv2R10Ast__loc_trLrRM11block_ctx_t(&try_end_loc_0, block_stack_ref_0, 0),
         _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM14make_fx_statusN14C_form__cexp_t2R10Ast__loc_tR9Ast__id_t(&try_end_loc_0, fx_status__0,
            &fx_status_exp_1, 0), _fx_catch_193);
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_826), _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            pop_exn_0, v_826, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0,
            fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0, return_used_ref_0,
            top_inline_ccode_ref_0, u1vals_0, &v_827, fx_fv), _fx_catch_193);
      FX_COPY_PTR(v_827.t1, &catch_ccode_0);
      FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &try_end_loc_0, &v_828, 0), _fx_catch_193);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypVoid, &try_end_loc_0, &v_829);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g21C_gen_code__COpAssign, fx_status_exp_1, v_828, &v_829, &v_830), _fx_catch_193);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_830, &v_831), _fx_catch_193);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_831, catch_ccode_0, true, &catch_ccode_1), _fx_catch_193);
      if (FX_REC_VARIANT_TAG(ctyp_0) == 8) {
         FX_COPY_PTR(catch_ccode_1, &catch_ccode_2);
      }
      else {
         FX_CALL(
            _fx_M11C_gen_typesFM13gen_free_codeLN15C_form__cstmt_t6N14C_form__cexp_tN14C_form__ctyp_tBBLN15C_form__cstmt_tR10Ast__loc_t(
               dst_exp_14, ctyp_0, true, true, catch_ccode_1, &try_end_loc_0, &catch_ccode_2, 0), _fx_catch_192);

      _fx_catch_192: ;
      }
      FX_CHECK_EXN(_fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            catch_e_0, dstexp_r_0, catch_ccode_2, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_832, fx_fv), _fx_catch_193);
      FX_COPY_PTR(v_832.t1, &catch_ccode_3);
      _fx_N17C_form__cbinary_t v_846;
      _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpLT, &v_846);
      FX_CALL(
         _fx_M10C_gen_codeFM14make_fx_statusN14C_form__cexp_t2R10Ast__loc_tR9Ast__id_t(&try_end_loc_0, fx_status__0, &v_833, 0),
         _fx_catch_193);
      FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &try_end_loc_0, &v_834, 0), _fx_catch_193);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &try_end_loc_0, &v_835);
      FX_CALL(
         _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &v_846, v_833, v_834, &v_835, &check_neg_status_0), _fx_catch_193);
      _fx_R10Ast__loc_t catch_loc_0;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(catch_e_0, &catch_loc_0, 0), _fx_catch_193);
      FX_CALL(
         _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(catch_ccode_3, &catch_loc_0, &v_836, 0),
         _fx_catch_193);
      FX_CALL(_fx_M6C_formFM8CStmtNopN15C_form__cstmt_t1R10Ast__loc_t(&try_end_loc_0, &v_837), _fx_catch_193);
      FX_CALL(
         _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
            check_neg_status_0, v_836, v_837, &catch_loc_0, &catch_clause_0, 0), _fx_catch_193);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(catch_clause_0, ccode_160, true, &v_838), _fx_catch_193);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dst_exp_14, v_838, &v_1);

   _fx_catch_193: ;
      if (v_838) {
         _fx_free_LN15C_form__cstmt_t(&v_838);
      }
      if (catch_clause_0) {
         _fx_free_N15C_form__cstmt_t(&catch_clause_0);
      }
      if (v_837) {
         _fx_free_N15C_form__cstmt_t(&v_837);
      }
      if (v_836) {
         _fx_free_N15C_form__cstmt_t(&v_836);
      }
      if (check_neg_status_0) {
         _fx_free_N14C_form__cexp_t(&check_neg_status_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_835);
      if (v_834) {
         _fx_free_N14C_form__cexp_t(&v_834);
      }
      if (v_833) {
         _fx_free_N14C_form__cexp_t(&v_833);
      }
      if (catch_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&catch_ccode_3);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_832);
      if (catch_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&catch_ccode_2);
      }
      if (catch_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&catch_ccode_1);
      }
      if (v_831) {
         _fx_free_N15C_form__cstmt_t(&v_831);
      }
      if (v_830) {
         _fx_free_N14C_form__cexp_t(&v_830);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_829);
      if (v_828) {
         _fx_free_N14C_form__cexp_t(&v_828);
      }
      if (catch_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&catch_ccode_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_827);
      if (v_826) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_826);
      }
      if (fx_status_exp_1) {
         _fx_free_N14C_form__cexp_t(&fx_status_exp_1);
      }
      if (ccode_160) {
         _fx_free_LN15C_form__cstmt_t(&ccode_160);
      }
      if (v_825) {
         _fx_free_LN15C_form__cstmt_t(&v_825);
      }
      if (v_824) {
         _fx_free_LN15C_form__cstmt_t(&v_824);
      }
      if (v_823) {
         _fx_free_LN15C_form__cstmt_t(&v_823);
      }
      if (v_822) {
         _fx_free_N15C_form__cstmt_t(&v_822);
      }
      if (epilogue_1) {
         _fx_free_LN15C_form__cstmt_t(&epilogue_1);
      }
      if (bctx_prologue_1) {
         _fx_free_LN15C_form__cstmt_t(&bctx_prologue_1);
      }
      if (bctx_cleanup_1) {
         _fx_free_LN15C_form__cstmt_t(&bctx_cleanup_1);
      }
      if (bctx_try_0) {
         _fx_free_rR23C_gen_code__block_ctx_t(&bctx_try_0);
      }
      if (try_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&try_ccode_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_821);
      if (ccode_159) {
         _fx_free_LN15C_form__cstmt_t(&ccode_159);
      }
      if (dst_exp_14) {
         _fx_free_N14C_form__cexp_t(&dst_exp_14);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_820);
      if (catch_e_0) {
         _fx_free_N14K_form__kexp_t(&catch_e_0);
      }
      if (pop_exn_0) {
         _fx_free_N14K_form__kexp_t(&pop_exn_0);
      }
      _fx_free_Ta2N14K_form__kexp_t(&v_819);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 24) {
      _fx_N14C_form__cexp_t lbl_6 = 0;
      _fx_LN15C_form__cstmt_t ccode_161 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_847 = {0};
      _fx_N14C_form__cexp_t i_exp_12 = 0;
      _fx_LN15C_form__cstmt_t ccode_162 = 0;
      _fx_N14C_form__cexp_t v_848 = 0;
      _fx_LN14C_form__cexp_t v_849 = 0;
      _fx_N14C_form__cexp_t throw_exp_0 = 0;
      _fx_N15C_form__cstmt_t v_850 = 0;
      _fx_T3R9Ast__id_tBR10Ast__loc_t* vcase_21 = &kexp_0->u.KExpThrow;
      _fx_R9Ast__id_t* i_7 = &vcase_21->t0;
      FX_CALL(
         _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &lbl_6, 0), _fx_catch_198);
      if (vcase_21->t1) {
         FX_CALL(
            _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
               i_7, false, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
               &v_847, 0), _fx_catch_198);
         FX_COPY_PTR(v_847.t0, &i_exp_12);
         FX_COPY_PTR(v_847.t1, &ccode_162);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(i_exp_12, &v_848, 0), _fx_catch_198);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_6, 0, true, &v_849), _fx_catch_198);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_848, v_849, false, &v_849), _fx_catch_198);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g22C_form__std_FX_RETHROW, v_849, _fx_g20C_gen_code__CTypVoid, &kloc_0, &throw_exp_0, 0), _fx_catch_198);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(throw_exp_0, &v_850), _fx_catch_198);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_850, ccode_162, true, &ccode_161), _fx_catch_198);
      }
      else {
         _fx_Nt6option1R9Ast__id_t v_851;
         FX_CALL(
            _fx_M10C_gen_codeFM8find_optNt6option1R9Ast__id_t2Rt6Map__t2R9Ast__id_tR9Ast__id_tR9Ast__id_t(
               &_fx_g23Ast__builtin_exceptions, i_7, &v_851, 0), _fx_catch_198);
         if (v_851.tag == 2) {
            fx_str_t v_852 = {0};
            fx_str_t v_853 = {0};
            _fx_N14C_form__cexp_t i_exp_13 = 0;
            _fx_LN14C_form__cexp_t v_854 = 0;
            _fx_N14C_form__cexp_t throw_exp_1 = 0;
            _fx_N15C_form__cstmt_t v_855 = 0;
            FX_CALL(_fx_M3AstFM2ppS1RM4id_t(i_7, &v_852, 0), _fx_catch_194);
            fx_str_t slit_177 = FX_MAKE_STR("FX_EXN_");
            {
               const fx_str_t strs_32[] = { slit_177, v_852 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_32, 2, &v_853), _fx_catch_194);
            }
            _fx_R9Ast__id_t i_8;
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&v_853, &i_8, 0), _fx_catch_194);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&i_8,
                  _fx_g20C_gen_code__CTypCInt, &kloc_0, &i_exp_13, 0), _fx_catch_194);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_6, 0, true, &v_854), _fx_catch_194);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(i_exp_13, v_854, false, &v_854), _fx_catch_194);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g25C_form__std_FX_FAST_THROW, v_854, _fx_g20C_gen_code__CTypVoid, &kloc_0, &throw_exp_1, 0),
               _fx_catch_194);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(throw_exp_1, &v_855), _fx_catch_194);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_855, ccode_0, true, &ccode_161), _fx_catch_194);

         _fx_catch_194: ;
            if (v_855) {
               _fx_free_N15C_form__cstmt_t(&v_855);
            }
            if (throw_exp_1) {
               _fx_free_N14C_form__cexp_t(&throw_exp_1);
            }
            if (v_854) {
               _fx_free_LN14C_form__cexp_t(&v_854);
            }
            if (i_exp_13) {
               _fx_free_N14C_form__cexp_t(&i_exp_13);
            }
            FX_FREE_STR(&v_853);
            FX_FREE_STR(&v_852);
         }
         else {
            _fx_N15K_form__kinfo_t v_856 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_857 = {0};
            _fx_N14C_form__cexp_t i_exp_14 = 0;
            _fx_LN15C_form__cstmt_t ccode_163 = 0;
            _fx_N14C_form__cexp_t v_858 = 0;
            _fx_N14C_form__cexp_t v_859 = 0;
            _fx_LN14C_form__cexp_t v_860 = 0;
            _fx_N14C_form__cexp_t throw_exp_2 = 0;
            _fx_N15C_form__cstmt_t v_861 = 0;
            FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(i_7, &kloc_0, &v_856, 0), _fx_catch_197);
            int tag_26 = v_856.tag;
            bool move_f_0;
            if (tag_26 == 4) {
               move_f_0 = false; goto _fx_endmatch_30;
            }
            if (tag_26 == 2) {
               if (FX_REC_VARIANT_TAG(v_856.u.KVal.kv_typ) == 21) {
                  FX_CALL(_fx_M10C_gen_codeFM3memB2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(u1vals_0, i_7, &move_f_0, 0),
                     _fx_catch_195);

               _fx_catch_195: ;
                  goto _fx_endmatch_30;
               }
            }
            fx_exn_t v_862 = {0};
            fx_str_t slit_178 = FX_MAKE_STR("cgen: throw is applied to neither exception nor value of \'exn\' type");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_178, &v_862, 0), _fx_catch_196);
            FX_THROW(&v_862, false, _fx_catch_196);

         _fx_catch_196: ;
            fx_free_exn(&v_862);

         _fx_endmatch_30: ;
            FX_CHECK_EXN(_fx_catch_197);
            FX_CALL(
               _fx_M10C_gen_codeFM7id2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t9R9Ast__id_tBLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
                  i_7, move_f_0, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
                  &v_857, 0), _fx_catch_197);
            FX_COPY_PTR(v_857.t0, &i_exp_14);
            FX_COPY_PTR(v_857.t1, &ccode_163);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(i_exp_14, &v_858, 0), _fx_catch_197);
            FX_CALL(_fx_M6C_formFM13make_bool_expN14C_form__cexp_t2BR10Ast__loc_t(move_f_0, &kloc_0, &v_859, 0), _fx_catch_197);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_6, 0, true, &v_860), _fx_catch_197);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_859, v_860, false, &v_860), _fx_catch_197);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_858, v_860, false, &v_860), _fx_catch_197);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g20C_form__std_FX_THROW, v_860, _fx_g20C_gen_code__CTypVoid, &kloc_0, &throw_exp_2, 0), _fx_catch_197);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(throw_exp_2, &v_861), _fx_catch_197);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_861, ccode_163, true, &ccode_161), _fx_catch_197);

         _fx_catch_197: ;
            if (v_861) {
               _fx_free_N15C_form__cstmt_t(&v_861);
            }
            if (throw_exp_2) {
               _fx_free_N14C_form__cexp_t(&throw_exp_2);
            }
            if (v_860) {
               _fx_free_LN14C_form__cexp_t(&v_860);
            }
            if (v_859) {
               _fx_free_N14C_form__cexp_t(&v_859);
            }
            if (v_858) {
               _fx_free_N14C_form__cexp_t(&v_858);
            }
            if (ccode_163) {
               _fx_free_LN15C_form__cstmt_t(&ccode_163);
            }
            if (i_exp_14) {
               _fx_free_N14C_form__cexp_t(&i_exp_14);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_857);
            _fx_free_N15K_form__kinfo_t(&v_856);
         }
         FX_CHECK_EXN(_fx_catch_198);
      }
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_161, &v_1);

   _fx_catch_198: ;
      if (v_850) {
         _fx_free_N15C_form__cstmt_t(&v_850);
      }
      if (throw_exp_0) {
         _fx_free_N14C_form__cexp_t(&throw_exp_0);
      }
      if (v_849) {
         _fx_free_LN14C_form__cexp_t(&v_849);
      }
      if (v_848) {
         _fx_free_N14C_form__cexp_t(&v_848);
      }
      if (ccode_162) {
         _fx_free_LN15C_form__cstmt_t(&ccode_162);
      }
      if (i_exp_12) {
         _fx_free_N14C_form__cexp_t(&i_exp_12);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_847);
      if (ccode_161) {
         _fx_free_LN15C_form__cstmt_t(&ccode_161);
      }
      if (lbl_6) {
         _fx_free_N14C_form__cexp_t(&lbl_6);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 25) {
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_863 = {0};
      _fx_N14C_form__cexp_t ce1_9 = 0;
      _fx_LN15C_form__cstmt_t ccode_164 = 0;
      _fx_N14K_form__ktyp_t atyp_0 = 0;
      _fx_N14C_form__ctyp_t ctyp_3 = 0;
      _fx_N14C_form__cexp_t v_864 = 0;
      _fx_T3N14K_form__atom_tN14K_form__ktyp_tR10Ast__loc_t* vcase_22 = &kexp_0->u.KExpCast;
      _fx_N14K_form__atom_t* a1_2 = &vcase_22->t0;
      FX_CALL(
         atom2cexp_0.fp(a1_2, ccode_0, &kloc_0, block_stack_ref_0, defined_syms_ref_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0,
            &v_863, atom2cexp_0.fcv), _fx_catch_203);
      FX_COPY_PTR(v_863.t0, &ce1_9);
      FX_COPY_PTR(v_863.t1, &ccode_164);
      FX_CALL(_fx_M6K_formFM13get_atom_ktypN14K_form__ktyp_t2N14K_form__atom_tR10Ast__loc_t(a1_2, &kloc_0, &atyp_0, 0),
         _fx_catch_203);
      FX_CALL(_fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(vcase_22->t1, &kloc_0, &ctyp_3, 0),
         _fx_catch_203);
      if (FX_REC_VARIANT_TAG(atyp_0) == 5) {
         if (atyp_0->u.KTypFloat == 16) {
            if (FX_REC_VARIANT_TAG(ctyp_3) == 7) {
               if (ctyp_3->u.CTypFloat == 32) {
                  _fx_LN14C_form__cexp_t v_865 = 0;
                  _fx_N14C_form__ctyp_t v_866 = 0;
                  _fx_R9Ast__id_t v_867;
                  fx_str_t slit_179 = FX_MAKE_STR("FX_FLOAT");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_179, &v_867, 0), _fx_catch_199);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(ce1_9, 0, true, &v_865), _fx_catch_199);
                  FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(32, &v_866), _fx_catch_199);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_867, v_865, v_866, &kloc_0, &v_864, 0), _fx_catch_199);

               _fx_catch_199: ;
                  if (v_866) {
                     _fx_free_N14C_form__ctyp_t(&v_866);
                  }
                  if (v_865) {
                     _fx_free_LN14C_form__cexp_t(&v_865);
                  }
                  goto _fx_endmatch_31;
               }
            }
         }
      }
      if (FX_REC_VARIANT_TAG(atyp_0) == 5) {
         if (atyp_0->u.KTypFloat == 16) {
            _fx_LN14C_form__cexp_t v_868 = 0;
            _fx_N14C_form__ctyp_t v_869 = 0;
            _fx_N14C_form__cexp_t v_870 = 0;
            _fx_R9Ast__id_t v_871;
            fx_str_t slit_180 = FX_MAKE_STR("FX_FLOAT");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_180, &v_871, 0), _fx_catch_200);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce1_9, 0, true, &v_868), _fx_catch_200);
            FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(32, &v_869), _fx_catch_200);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_871,
                  v_868, v_869, &kloc_0, &v_870, 0), _fx_catch_200);
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_870, ctyp_3, &kloc_0,
                  &v_864), _fx_catch_200);

         _fx_catch_200: ;
            if (v_870) {
               _fx_free_N14C_form__cexp_t(&v_870);
            }
            if (v_869) {
               _fx_free_N14C_form__ctyp_t(&v_869);
            }
            if (v_868) {
               _fx_free_LN14C_form__cexp_t(&v_868);
            }
            goto _fx_endmatch_31;
         }
      }
      if (FX_REC_VARIANT_TAG(ctyp_3) == 7) {
         if (ctyp_3->u.CTypFloat == 16) {
            _fx_LN14C_form__cexp_t v_872 = 0;
            _fx_N14C_form__ctyp_t v_873 = 0;
            _fx_R9Ast__id_t v_874;
            fx_str_t slit_181 = FX_MAKE_STR("FX_FLOAT16");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_181, &v_874, 0), _fx_catch_201);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(ce1_9, 0, true, &v_872), _fx_catch_201);
            FX_CALL(_fx_M6C_formFM9CTypFloatN14C_form__ctyp_t1i(16, &v_873), _fx_catch_201);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_874,
                  v_872, v_873, &kloc_0, &v_864, 0), _fx_catch_201);

         _fx_catch_201: ;
            if (v_873) {
               _fx_free_N14C_form__ctyp_t(&v_873);
            }
            if (v_872) {
               _fx_free_LN14C_form__cexp_t(&v_872);
            }
            goto _fx_endmatch_31;
         }
      }
      FX_CALL(
         _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(ce1_9, ctyp_3, &kloc_0,
            &v_864), _fx_catch_202);

   _fx_catch_202: ;

   _fx_endmatch_31: ;
      FX_CHECK_EXN(_fx_catch_203);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(true, v_864, ccode_164, &v_1);

   _fx_catch_203: ;
      if (v_864) {
         _fx_free_N14C_form__cexp_t(&v_864);
      }
      if (ctyp_3) {
         _fx_free_N14C_form__ctyp_t(&ctyp_3);
      }
      if (atyp_0) {
         _fx_free_N14K_form__ktyp_t(&atyp_0);
      }
      if (ccode_164) {
         _fx_free_LN15C_form__cstmt_t(&ccode_164);
      }
      if (ce1_9) {
         _fx_free_N14C_form__cexp_t(&ce1_9);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_863);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 26) {
      _fx_N14C_form__cexp_t map_lbl_0 = 0;
      _fx_Nt10Hashset__t1R9Ast__id_t decl_inside_for_0 = 0;
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t e_idoml_l_0 = 0;
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t e_idoml_l_1 = 0;
      _fx_N14C_form__cexp_t glob_status_0 = 0;
      _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t v_875 = {0};
      _fx_R16Ast__val_flags_t v_876 = {0};
      _fx_N14C_form__cexp_t v_877 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_878 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_879 = {0};
      _fx_N14C_form__cexp_t par_status_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_165 = 0;
      _fx_R16Ast__val_flags_t v_880 = {0};
      _fx_N14C_form__cexp_t v_881 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_882 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_883 = {0};
      _fx_N14C_form__cexp_t nested_status_0 = 0;
      _fx_LN15C_form__cstmt_t decl_nested_status_0 = 0;
      _fx_N14C_form__cexp_t v_884 = 0;
      _fx_N14C_form__cexp_t par_status_1 = 0;
      _fx_LN15C_form__cstmt_t ccode_166 = 0;
      _fx_N14C_form__cexp_t nested_status_1 = 0;
      _fx_LN15C_form__cstmt_t decl_nested_status_1 = 0;
      _fx_N14K_form__ktyp_t v_885 = 0;
      _fx_LN14K_form__ktyp_t coll_typs_0 = 0;
      _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t
         __fold_result___19 = {0};
      _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t
         v_886 = {0};
      _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_167 = 0;
      _fx_LN15C_form__cstmt_t finalize_ccode_0 = 0;
      _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_1 = 0;
      _fx_FPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrR23C_gen_code__block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB
         form_map_0 = {0};
      _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_887 = {0};
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_888 = 0;
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_889 = 0;
      _fx_Ta2LN15C_form__cstmt_t v_890 = {0};
      _fx_LN15C_form__cstmt_t pre_map_ccode_0 = 0;
      _fx_LN15C_form__cstmt_t map_ccode_0 = 0;
      _fx_LN15C_form__cstmt_t map_ccode_1 = 0;
      _fx_LN14C_form__cexp_t v_891 = 0;
      _fx_N14C_form__cexp_t update_exn_parallel_0 = 0;
      _fx_N15C_form__cstmt_t v_892 = 0;
      _fx_LN15C_form__cstmt_t map_ccode_2 = 0;
      _fx_LN15C_form__cstmt_t map_ccode_3 = 0;
      _fx_LN14C_form__cexp_t cargs_6 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_893 = {0};
      _fx_N14C_form__cexp_t t_exp_2 = 0;
      _fx_LN15C_form__cstmt_t map_ccode_4 = 0;
      _fx_N14C_form__cexp_t v_894 = 0;
      _fx_LN14C_form__cexp_t v_895 = 0;
      _fx_LN14C_form__cexp_t v_896 = 0;
      _fx_N14C_form__cexp_t call_mktup_1 = 0;
      _fx_N15C_form__cstmt_t v_897 = 0;
      _fx_LN15C_form__cstmt_t v_898 = 0;
      _fx_LN15C_form__cstmt_t v_899 = 0;
      _fx_T4LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tT2N14K_form__ktyp_tR10Ast__loc_t*
         vcase_23 = &kexp_0->u.KExpMap;
      _fx_R16Ast__for_flags_t* flags_0 = &vcase_23->t2;
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t e_idoml_l_2 = vcase_23->t0;
      FX_CALL(
         _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &map_lbl_0, 0), _fx_catch_218);
      _fx_R10Ast__loc_t for_loc_0;
      FX_CALL(_fx_M3AstFM13get_start_locRM5loc_t1RM5loc_t(&kloc_0, &for_loc_0, 0), _fx_catch_218);
      _fx_R10Ast__loc_t end_for_loc_0;
      FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(&kloc_0, &end_for_loc_0, 0), _fx_catch_218);
      _fx_N15Ast__for_make_t for_flag_make_0 = flags_0->for_flag_make;
      bool need_make_array_0 = for_flag_make_0.tag == 2;
      bool unzip_mode_0 = flags_0->for_flag_unzip;
      int_ nfors_0;
      FX_CALL(
         _fx_M10C_gen_codeFM8length1_i1LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(e_idoml_l_2, &nfors_0, 0),
         _fx_catch_218);
      bool pre_alloc_array_0;
      if (!need_make_array_0) {
         pre_alloc_array_0 = false;
      }
      else {
         FX_CALL(_fx_M3AstFM16empty_id_hashsetNt10Hashset__t1RM4id_t1i(256, &decl_inside_for_0, 0), _fx_catch_218);
         bool __fold_result___20 = true;
         FX_COPY_PTR(e_idoml_l_2, &e_idoml_l_0);
         _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t lst_22 = e_idoml_l_0;
         for (; lst_22; lst_22 = lst_22->tl) {
            _fx_N14K_form__kexp_t e_14 = 0;
            _fx_LT2R9Ast__id_tN13K_form__dom_t idoml_0 = 0;
            _fx_LR9Ast__id_t idxl_0 = 0;
            _fx_LN14K_form__kexp_t v_900 = 0;
            _fx_Nt10Hashset__t1R9Ast__id_t v_901 = 0;
            _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* __pat___6 = &lst_22->hd;
            FX_COPY_PTR(__pat___6->t0, &e_14);
            FX_COPY_PTR(__pat___6->t1, &idoml_0);
            FX_COPY_PTR(__pat___6->t2, &idxl_0);
            FX_CALL(_fx_cons_LN14K_form__kexp_t(e_14, 0, true, &v_900), _fx_catch_208);
            FX_CALL(_fx_M6K_formFM8declaredNt10Hashset__t1R9Ast__id_t2LN14K_form__kexp_ti(v_900, 256, &v_901, 0),
               _fx_catch_208);
            FX_CALL(
               _fx_M10C_gen_codeFM5unionv2Nt10Hashset__t1R9Ast__id_tNt10Hashset__t1R9Ast__id_t(decl_inside_for_0, v_901, 0),
               _fx_catch_208);
            _fx_LR9Ast__id_t lst_23 = idxl_0;
            for (; lst_23; lst_23 = lst_23->tl) {
               _fx_R9Ast__id_t* i_9 = &lst_23->hd;
               FX_CALL(_fx_M10C_gen_codeFM3addv2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(decl_inside_for_0, i_9, 0),
                  _fx_catch_204);

            _fx_catch_204: ;
               FX_CHECK_EXN(_fx_catch_208);
            }
            bool __fold_result___21 = true;
            _fx_LT2R9Ast__id_tN13K_form__dom_t lst_24 = idoml_0;
            for (; lst_24; lst_24 = lst_24->tl) {
               _fx_N13K_form__dom_t dom_0 = {0};
               _fx_T2R9Ast__id_tN13K_form__dom_t* __pat___7 = &lst_24->hd;
               _fx_R9Ast__id_t i_10 = __pat___7->t0;
               _fx_copy_N13K_form__dom_t(&__pat___7->t1, &dom_0);
               FX_CALL(_fx_M10C_gen_codeFM3addv2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(decl_inside_for_0, &i_10, 0),
                  _fx_catch_207);
               int tag_27 = dom_0.tag;
               bool v_902;
               if (tag_27 == 1) {
                  _fx_N14K_form__atom_t* v_903 = &dom_0.u.DomainElem;
                  if (v_903->tag == 1) {
                     _fx_R17K_form__kdefval_t v_904 = {0};
                     _fx_R16Ast__val_flags_t kv_flags_0 = {0};
                     _fx_N14K_form__ktyp_t kv_typ_0 = 0;
                     _fx_R9Ast__id_t* col_0 = &v_903->u.AtomId;
                     FX_CALL(_fx_M6K_formFM8get_kvalRM9kdefval_t2R9Ast__id_tR10Ast__loc_t(col_0, &kloc_0, &v_904, 0),
                        _fx_catch_205);
                     _fx_copy_R16Ast__val_flags_t(&v_904.kv_flags, &kv_flags_0);
                     FX_COPY_PTR(v_904.kv_typ, &kv_typ_0);
                     bool t_12;
                     if (!kv_flags_0.val_flag_mutable) {
                        int tag_28 = FX_REC_VARIANT_TAG(kv_typ_0);
                        bool res_21;
                        if (tag_28 == 17) {
                           res_21 = true;
                        }
                        else if (tag_28 == 10) {
                           res_21 = true;
                        }
                        else {
                           res_21 = false;
                        }
                        FX_CHECK_EXN(_fx_catch_205);
                        if (res_21) {
                           t_12 = true; goto _fx_endmatch_32;
                        }
                        t_12 = false;

                     _fx_endmatch_32: ;
                        FX_CHECK_EXN(_fx_catch_205);
                     }
                     else {
                        t_12 = false;
                     }
                     if (t_12) {
                        bool v_905;
                        FX_CALL(
                           _fx_M10C_gen_codeFM3memB2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(decl_inside_for_0, col_0, &v_905, 0),
                           _fx_catch_205);
                        v_902 = !v_905;
                     }
                     else {
                        v_902 = false;
                     }

                  _fx_catch_205: ;
                     if (kv_typ_0) {
                        _fx_free_N14K_form__ktyp_t(&kv_typ_0);
                     }
                     _fx_free_R16Ast__val_flags_t(&kv_flags_0);
                     _fx_free_R17K_form__kdefval_t(&v_904);
                     goto _fx_endmatch_33;
                  }
               }
               if (tag_27 == 1) {
                  _fx_N14K_form__atom_t* v_906 = &dom_0.u.DomainElem;
                  if (v_906->tag == 2) {
                     if (v_906->u.AtomLit.tag == 5) {
                        v_902 = true; goto _fx_endmatch_33;
                     }
                  }
               }
               if (tag_27 == 3) {
                  _fx_Ta3N14K_form__atom_t* vcase_24 = &dom_0.u.DomainRange;
                  bool res_22;
                  FX_CALL(
                     _fx_M10C_gen_codeFM16check_range_elemB3N14K_form__atom_tNt10Hashset__t1R9Ast__id_tR10Ast__loc_t(
                        &vcase_24->t0, decl_inside_for_0, &kloc_0, &res_22, 0), _fx_catch_206);
                  bool t_13;
                  if (res_22) {
                     FX_CALL(
                        _fx_M10C_gen_codeFM16check_range_elemB3N14K_form__atom_tNt10Hashset__t1R9Ast__id_tR10Ast__loc_t(
                           &vcase_24->t1, decl_inside_for_0, &kloc_0, &t_13, 0), _fx_catch_206);
                  }
                  else {
                     t_13 = false;
                  }
                  if (t_13) {
                     FX_CALL(
                        _fx_M10C_gen_codeFM16check_range_elemB3N14K_form__atom_tNt10Hashset__t1R9Ast__id_tR10Ast__loc_t(
                           &vcase_24->t2, decl_inside_for_0, &kloc_0, &v_902, 0), _fx_catch_206);
                  }
                  else {
                     v_902 = false;
                  }

               _fx_catch_206: ;
                  goto _fx_endmatch_33;
               }
               v_902 = false;

            _fx_endmatch_33: ;
               FX_CHECK_EXN(_fx_catch_207);
               if (!v_902) {
                  __fold_result___21 = false; FX_BREAK(_fx_catch_207);
               }

            _fx_catch_207: ;
               _fx_free_N13K_form__dom_t(&dom_0);
               FX_CHECK_BREAK();
               FX_CHECK_EXN(_fx_catch_208);
            }
            if (!__fold_result___21) {
               __fold_result___20 = false; FX_BREAK(_fx_catch_208);
            }

         _fx_catch_208: ;
            if (v_901) {
               _fx_free_Nt10Hashset__t1R9Ast__id_t(&v_901);
            }
            if (v_900) {
               _fx_free_LN14K_form__kexp_t(&v_900);
            }
            FX_FREE_LIST_SIMPLE(&idxl_0);
            if (idoml_0) {
               _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&idoml_0);
            }
            if (e_14) {
               _fx_free_N14K_form__kexp_t(&e_14);
            }
            FX_CHECK_BREAK();
            FX_CHECK_EXN(_fx_catch_218);
         }
         pre_alloc_array_0 = __fold_result___20;
      }
      int_ __fold_result___22 = 0;
      int_ for_idx_0 = 0;
      FX_COPY_PTR(e_idoml_l_2, &e_idoml_l_1);
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t lst_25 = e_idoml_l_1;
      for (; lst_25; lst_25 = lst_25->tl, for_idx_0 += 1) {
         _fx_LT2R9Ast__id_tN13K_form__dom_t idoml_1 = 0;
         _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* __pat___8 = &lst_25->hd;
         FX_COPY_PTR(__pat___8->t1, &idoml_1);
         int_ ndims_i_0;
         FX_CALL(
            _fx_M10C_gen_codeFM17compute_for_ndimsi4iiLT2R9Ast__id_tN13K_form__dom_tR10Ast__loc_t(for_idx_0, nfors_0, idoml_1,
               &for_loc_0, &ndims_i_0, 0), _fx_catch_209);
         __fold_result___22 = __fold_result___22 + ndims_i_0;

      _fx_catch_209: ;
         if (idoml_1) {
            _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&idoml_1);
         }
         FX_CHECK_EXN(_fx_catch_218);
      }
      int_ ndims_3 = __fold_result___22;
      bool is_parallel_map_0;
      if (pre_alloc_array_0) {
         is_parallel_map_0 = flags_0->for_flag_parallel;
      }
      else {
         is_parallel_map_0 = false;
      }
      FX_CALL(
         _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(fx_status__0,
            _fx_g20C_gen_code__CTypCInt, &kloc_0, &glob_status_0, 0), _fx_catch_218);
      if (is_parallel_map_0) {
         _fx_R9Ast__id_t v_907;
         fx_str_t slit_182 = FX_MAKE_STR("par_status");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_182, &v_907, 0), _fx_catch_218);
         FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_876, 0), _fx_catch_218);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_877, 0), _fx_catch_218);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_877, &v_878);
         fx_str_t slit_183 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_907, _fx_g20C_gen_code__CTypCInt, &v_876, &slit_183, &v_878, ccode_0, &kloc_0, &v_879, 0), _fx_catch_218);
         FX_COPY_PTR(v_879.t0, &par_status_0);
         FX_COPY_PTR(v_879.t1, &ccode_165);
         _fx_R9Ast__id_t v_908;
         fx_str_t slit_184 = FX_MAKE_STR("status");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_184, &v_908, 0), _fx_catch_218);
         FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_880, 0), _fx_catch_218);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_881, 0), _fx_catch_218);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_881, &v_882);
         fx_str_t slit_185 = FX_MAKE_STR("fx_status");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_908, _fx_g20C_gen_code__CTypCInt, &v_880, &slit_185, &v_882, 0, &kloc_0, &v_883, 0), _fx_catch_218);
         FX_COPY_PTR(v_883.t0, &nested_status_0);
         FX_COPY_PTR(v_883.t1, &decl_nested_status_0);
         _fx_make_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(par_status_0, ccode_165,
            nested_status_0, decl_nested_status_0, &v_875);
      }
      else {
         FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_884, 0), _fx_catch_218);
         _fx_make_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(v_884, ccode_0, glob_status_0, 0,
            &v_875);
      }
      FX_COPY_PTR(v_875.t0, &par_status_1);
      FX_COPY_PTR(v_875.t1, &ccode_166);
      FX_COPY_PTR(v_875.t2, &nested_status_1);
      FX_COPY_PTR(v_875.t3, &decl_nested_status_1);
      FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(ktyp_0, &for_loc_0, &v_885, 0),
         _fx_catch_218);
      if (unzip_mode_0 == false) {
         FX_CALL(_fx_cons_LN14K_form__ktyp_t(ktyp_0, 0, true, &coll_typs_0), _fx_catch_210);

      _fx_catch_210: ;
         goto _fx_endmatch_34;
      }
      if (unzip_mode_0 == true) {
         if (FX_REC_VARIANT_TAG(v_885) == 14) {
            FX_COPY_PTR(v_885->u.KTypTuple, &coll_typs_0); goto _fx_endmatch_34;
         }
      }
      fx_exn_t v_909 = {0};
      fx_str_t slit_186 = FX_MAKE_STR("cgen: the result of @unzip comprehension should be a tuple");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_186, &v_909, 0), _fx_catch_211);
      FX_THROW(&v_909, false, _fx_catch_211);

   _fx_catch_211: ;
      fx_free_exn(&v_909);

   _fx_endmatch_34: ;
      FX_CHECK_EXN(_fx_catch_218);
      _fx_make_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         0, ccode_166, 0, &__fold_result___19);
      _fx_LN14K_form__ktyp_t lst_26 = coll_typs_0;
      for (; lst_26; lst_26 = lst_26->tl) {
         _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t
            v_910 = {0};
         _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_2 = 0;
         _fx_LN15C_form__cstmt_t ccode_168 = 0;
         _fx_LN15C_form__cstmt_t finalize_ccode_1 = 0;
         _fx_N14C_form__ctyp_t coll_ctyp_0 = 0;
         _fx_N14K_form__ktyp_t v_911 = 0;
         _fx_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t
            v_912 = {0};
         _fx_N14K_form__ktyp_t coll_typ_0 = lst_26->hd;
         _fx_copy_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            &__fold_result___19, &v_910);
         FX_COPY_PTR(v_910.t0, &dst_data_2);
         FX_COPY_PTR(v_910.t1, &ccode_168);
         FX_COPY_PTR(v_910.t2, &finalize_ccode_1);
         FX_CALL(
            _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(coll_typ_0, &kloc_0, &coll_ctyp_0,
               0), _fx_catch_216);
         FX_CALL(_fx_M6K_formFM10deref_ktypN14K_form__ktyp_t2N14K_form__ktyp_tR10Ast__loc_t(coll_typ_0, &kloc_0, &v_911, 0),
            _fx_catch_216);
         if (for_flag_make_0.tag == 2) {
            if (FX_REC_VARIANT_TAG(v_911) == 17) {
               if (FX_REC_VARIANT_TAG(coll_ctyp_0) == 19) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_913 = {0};
                  _fx_R16Ast__val_flags_t v_914 = {0};
                  _fx_N14C_form__cexp_t dst_exp_15 = 0;
                  _fx_LN15C_form__cstmt_t ccode_169 = 0;
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_915 = {0};
                  _fx_N14C_form__cexp_t v_916 = 0;
                  _fx_N14C_form__ctyp_t v_917 = 0;
                  _fx_R16Ast__val_flags_t v_918 = {0};
                  _fx_N14C_form__cexp_t v_919 = 0;
                  _fx_Nt6option1N14C_form__cexp_t v_920 = {0};
                  _fx_N14C_form__cexp_t dst_ptr_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_170 = 0;
                  fx_str_t v_921 = {0};
                  fx_str_t v_922 = {0};
                  fx_str_t v_923 = {0};
                  fx_exn_t v_924 = {0};
                  _fx_N14C_form__cexp_t v_925 = 0;
                  _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_926 = {0};
                  _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_927 = 0;
                  _fx_T2iN14C_form__ctyp_t* vcase_25 = &coll_ctyp_0->u.CTypArray;
                  _fx_N14C_form__ctyp_t elemtyp_0 = vcase_25->t1;
                  int_ nd_0 = vcase_25->t0;
                  if (unzip_mode_0) {
                     _fx_R9Ast__id_t v_928;
                     fx_str_t slit_187 = FX_MAKE_STR("arr");
                     FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_187, &v_928, 0), _fx_catch_212);
                     FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_914, 0), _fx_catch_212);
                     FX_CALL(
                        _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                           &v_928, coll_ctyp_0, &v_914, &_fx_g18C_gen_code__None2_, ccode_168, &for_loc_0, block_stack_ref_0,
                           &v_913, 0), _fx_catch_212);
                  }
                  else {
                     fx_str_t slit_188 = FX_MAKE_STR("arr");
                     FX_CALL(
                        _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                           dstexp_r_0, &slit_188, coll_ctyp_0, ccode_168, &for_loc_0, block_stack_ref_0, km_idx_0, &v_913, 0),
                        _fx_catch_212);
                  }
                  FX_COPY_PTR(v_913.t0, &dst_exp_15);
                  FX_COPY_PTR(v_913.t1, &ccode_169);
                  if (is_parallel_map_0) {
                     FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_916, 0), _fx_catch_212);
                     _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_916, ccode_169, &v_915);
                  }
                  else {
                     _fx_R9Ast__id_t v_929;
                     fx_str_t slit_189 = FX_MAKE_STR("dstptr");
                     FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_189, &v_929, 0), _fx_catch_212);
                     FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elemtyp_0, &v_917, 0), _fx_catch_212);
                     FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_918, 0), _fx_catch_212);
                     FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&for_loc_0, &v_919, 0), _fx_catch_212);
                     _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_919, &v_920);
                     fx_str_t slit_190 = FX_MAKE_STR("");
                     FX_CALL(
                        _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                           &v_929, v_917, &v_918, &slit_190, &v_920, ccode_169, &for_loc_0, &v_915, 0), _fx_catch_212);
                  }
                  FX_COPY_PTR(v_915.t0, &dst_ptr_0);
                  FX_COPY_PTR(v_915.t1, &ccode_170);
                  if (nd_0 != ndims_3) {
                     FX_CALL(_fx_F6stringS1i(ndims_3, &v_921, 0), _fx_catch_212);
                     FX_CALL(_fx_F6stringS1i(nd_0, &v_922, 0), _fx_catch_212);
                     fx_str_t slit_191 = FX_MAKE_STR("cgen: invalid dimensionaly of array comprehension result (computed: ");
                     fx_str_t slit_192 = FX_MAKE_STR(", expected: ");
                     fx_str_t slit_193 = FX_MAKE_STR(")");
                     {
                        const fx_str_t strs_33[] = { slit_191, v_921, slit_192, v_922, slit_193 };
                        FX_CALL(fx_strjoin(0, 0, 0, strs_33, 5, &v_923), _fx_catch_212);
                     }
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_923, &v_924, 0), _fx_catch_212);
                     FX_THROW(&v_924, false, _fx_catch_212);
                  }
                  else {
                     FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(&for_loc_0, &v_925, 0),
                        _fx_catch_212);
                     _fx_make_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                        coll_ctyp_0, elemtyp_0, dst_exp_15, dst_ptr_0, v_925, &v_926);
                     FX_CALL(
                        _fx_cons_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                           &v_926, dst_data_2, true, &v_927), _fx_catch_212);
                     _fx_make_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                        v_927, ccode_170, finalize_ccode_1, &v_912);
                  }

               _fx_catch_212: ;
                  if (v_927) {
                     _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_927);
                  }
                  _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_926);
                  if (v_925) {
                     _fx_free_N14C_form__cexp_t(&v_925);
                  }
                  fx_free_exn(&v_924);
                  FX_FREE_STR(&v_923);
                  FX_FREE_STR(&v_922);
                  FX_FREE_STR(&v_921);
                  if (ccode_170) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_170);
                  }
                  if (dst_ptr_0) {
                     _fx_free_N14C_form__cexp_t(&dst_ptr_0);
                  }
                  _fx_free_Nt6option1N14C_form__cexp_t(&v_920);
                  if (v_919) {
                     _fx_free_N14C_form__cexp_t(&v_919);
                  }
                  _fx_free_R16Ast__val_flags_t(&v_918);
                  if (v_917) {
                     _fx_free_N14C_form__ctyp_t(&v_917);
                  }
                  if (v_916) {
                     _fx_free_N14C_form__cexp_t(&v_916);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_915);
                  if (ccode_169) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_169);
                  }
                  if (dst_exp_15) {
                     _fx_free_N14C_form__cexp_t(&dst_exp_15);
                  }
                  _fx_free_R16Ast__val_flags_t(&v_914);
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_913);
                  goto _fx_endmatch_35;
               }
            }
         }
         if (for_flag_make_0.tag == 4) {
            if (FX_REC_VARIANT_TAG(v_911) == 18) {
               if (FX_REC_VARIANT_TAG(coll_ctyp_0) == 20) {
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_930 = {0};
                  _fx_R16Ast__val_flags_t v_931 = {0};
                  _fx_N14C_form__cexp_t dst_exp_16 = 0;
                  _fx_LN15C_form__cstmt_t ccode_171 = 0;
                  _fx_Ta3N14C_form__cexp_t v_932 = {0};
                  _fx_N14C_form__cexp_t sizeof_elem_exp_3 = 0;
                  _fx_N14C_form__cexp_t free_f_exp_3 = 0;
                  _fx_N14C_form__cexp_t copy_f_exp_3 = 0;
                  _fx_N14C_form__ctyp_t iter_t_0 = 0;
                  _fx_R16Ast__val_flags_t v_933 = {0};
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_934 = {0};
                  _fx_N14C_form__cexp_t iter_exp_0 = 0;
                  _fx_LN15C_form__cstmt_t ccode_172 = 0;
                  _fx_N14C_form__cexp_t v_935 = 0;
                  _fx_LN14C_form__cexp_t v_936 = 0;
                  _fx_N14C_form__cexp_t call_start_write_0 = 0;
                  _fx_N14C_form__ctyp_t v_937 = 0;
                  _fx_R16Ast__val_flags_t v_938 = {0};
                  _fx_Nt6option1N14C_form__cexp_t v_939 = {0};
                  _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_940 = {0};
                  _fx_N14C_form__cexp_t dst_ptr_1 = 0;
                  _fx_LN15C_form__cstmt_t ccode_173 = 0;
                  _fx_LN14C_form__cexp_t v_941 = 0;
                  _fx_N14C_form__cexp_t call_end_write_0 = 0;
                  _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_942 = {0};
                  _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_943 = 0;
                  _fx_N15C_form__cstmt_t v_944 = 0;
                  _fx_LN15C_form__cstmt_t v_945 = 0;
                  _fx_N14C_form__ctyp_t elemtyp_1 = coll_ctyp_0->u.CTypVector;
                  if (unzip_mode_0) {
                     _fx_R9Ast__id_t v_946;
                     fx_str_t slit_194 = FX_MAKE_STR("vec");
                     FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_194, &v_946, 0), _fx_catch_213);
                     FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_931, 0), _fx_catch_213);
                     FX_CALL(
                        _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                           &v_946, coll_ctyp_0, &v_931, &_fx_g18C_gen_code__None2_, ccode_168, &for_loc_0, block_stack_ref_0,
                           &v_930, 0), _fx_catch_213);
                  }
                  else {
                     fx_str_t slit_195 = FX_MAKE_STR("vec");
                     FX_CALL(
                        _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                           dstexp_r_0, &slit_195, coll_ctyp_0, ccode_168, &for_loc_0, block_stack_ref_0, km_idx_0, &v_930, 0),
                        _fx_catch_213);
                  }
                  FX_COPY_PTR(v_930.t0, &dst_exp_16);
                  FX_COPY_PTR(v_930.t1, &ccode_171);
                  FX_CALL(
                     _fx_M10C_gen_codeFM23get_elem_size_free_copyTa3N14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elemtyp_1,
                        &for_loc_0, &v_932, 0), _fx_catch_213);
                  FX_COPY_PTR(v_932.t0, &sizeof_elem_exp_3);
                  FX_COPY_PTR(v_932.t1, &free_f_exp_3);
                  FX_COPY_PTR(v_932.t2, &copy_f_exp_3);
                  _fx_R9Ast__id_t v_947;
                  fx_str_t slit_196 = FX_MAKE_STR("fx_rrbiter_t");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_196, &v_947, 0), _fx_catch_213);
                  FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&v_947, &iter_t_0), _fx_catch_213);
                  _fx_R9Ast__id_t v_948;
                  fx_str_t slit_197 = FX_MAKE_STR("iter");
                  FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_197, &v_948, 0), _fx_catch_213);
                  FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_933, 0), _fx_catch_213);
                  fx_str_t slit_198 = FX_MAKE_STR("");
                  FX_CALL(
                     _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                        &v_948, iter_t_0, &v_933, &slit_198, &_fx_g18C_gen_code__None2_, ccode_171, &for_loc_0, &v_934, 0),
                     _fx_catch_213);
                  FX_COPY_PTR(v_934.t0, &iter_exp_0);
                  FX_COPY_PTR(v_934.t1, &ccode_172);
                  _fx_R9Ast__id_t v_949;
                  fx_str_t slit_199 = FX_MAKE_STR("FX_RRB_START_WRITE");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_199, &v_949, 0), _fx_catch_213);
                  FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elemtyp_1, &for_loc_0, &v_935),
                     _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(iter_exp_0, 0, true, &v_936), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_exp_16, v_936, false, &v_936), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(copy_f_exp_3, v_936, false, &v_936), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_3, v_936, false, &v_936), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(sizeof_elem_exp_3, v_936, false, &v_936), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(v_935, v_936, false, &v_936), _fx_catch_213);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_949, v_936, _fx_g23C_form__std_CTypVoidPtr, &for_loc_0, &call_start_write_0, 0), _fx_catch_213);
                  _fx_R9Ast__id_t v_950;
                  fx_str_t slit_200 = FX_MAKE_STR("dstptr");
                  FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_200, &v_950, 0), _fx_catch_213);
                  FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elemtyp_1, &v_937, 0), _fx_catch_213);
                  FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_938, 0), _fx_catch_213);
                  _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(call_start_write_0, &v_939);
                  fx_str_t slit_201 = FX_MAKE_STR("");
                  FX_CALL(
                     _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                        &v_950, v_937, &v_938, &slit_201, &v_939, ccode_172, &for_loc_0, &v_940, 0), _fx_catch_213);
                  FX_COPY_PTR(v_940.t0, &dst_ptr_1);
                  FX_COPY_PTR(v_940.t1, &ccode_173);
                  _fx_R9Ast__id_t v_951;
                  fx_str_t slit_202 = FX_MAKE_STR("FX_RRB_END_WRITE");
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_202, &v_951, 0), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_ptr_1, 0, true, &v_941), _fx_catch_213);
                  FX_CALL(_fx_cons_LN14C_form__cexp_t(iter_exp_0, v_941, false, &v_941), _fx_catch_213);
                  FX_CALL(
                     _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                        &v_951, v_941, _fx_g20C_gen_code__CTypVoid, &for_loc_0, &call_end_write_0, 0), _fx_catch_213);
                  _fx_make_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(coll_ctyp_0,
                     elemtyp_1, dst_exp_16, dst_ptr_1, iter_exp_0, &v_942);
                  FX_CALL(
                     _fx_cons_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_942,
                        dst_data_2, true, &v_943), _fx_catch_213);
                  FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_end_write_0, &v_944), _fx_catch_213);
                  FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_944, finalize_ccode_1, true, &v_945), _fx_catch_213);
                  _fx_make_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                     v_943, ccode_173, v_945, &v_912);

               _fx_catch_213: ;
                  if (v_945) {
                     _fx_free_LN15C_form__cstmt_t(&v_945);
                  }
                  if (v_944) {
                     _fx_free_N15C_form__cstmt_t(&v_944);
                  }
                  if (v_943) {
                     _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_943);
                  }
                  _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_942);
                  if (call_end_write_0) {
                     _fx_free_N14C_form__cexp_t(&call_end_write_0);
                  }
                  if (v_941) {
                     _fx_free_LN14C_form__cexp_t(&v_941);
                  }
                  if (ccode_173) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_173);
                  }
                  if (dst_ptr_1) {
                     _fx_free_N14C_form__cexp_t(&dst_ptr_1);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_940);
                  _fx_free_Nt6option1N14C_form__cexp_t(&v_939);
                  _fx_free_R16Ast__val_flags_t(&v_938);
                  if (v_937) {
                     _fx_free_N14C_form__ctyp_t(&v_937);
                  }
                  if (call_start_write_0) {
                     _fx_free_N14C_form__cexp_t(&call_start_write_0);
                  }
                  if (v_936) {
                     _fx_free_LN14C_form__cexp_t(&v_936);
                  }
                  if (v_935) {
                     _fx_free_N14C_form__cexp_t(&v_935);
                  }
                  if (ccode_172) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_172);
                  }
                  if (iter_exp_0) {
                     _fx_free_N14C_form__cexp_t(&iter_exp_0);
                  }
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_934);
                  _fx_free_R16Ast__val_flags_t(&v_933);
                  if (iter_t_0) {
                     _fx_free_N14C_form__ctyp_t(&iter_t_0);
                  }
                  if (copy_f_exp_3) {
                     _fx_free_N14C_form__cexp_t(&copy_f_exp_3);
                  }
                  if (free_f_exp_3) {
                     _fx_free_N14C_form__cexp_t(&free_f_exp_3);
                  }
                  if (sizeof_elem_exp_3) {
                     _fx_free_N14C_form__cexp_t(&sizeof_elem_exp_3);
                  }
                  _fx_free_Ta3N14C_form__cexp_t(&v_932);
                  if (ccode_171) {
                     _fx_free_LN15C_form__cstmt_t(&ccode_171);
                  }
                  if (dst_exp_16) {
                     _fx_free_N14C_form__cexp_t(&dst_exp_16);
                  }
                  _fx_free_R16Ast__val_flags_t(&v_931);
                  _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_930);
                  goto _fx_endmatch_35;
               }
            }
         }
         if (for_flag_make_0.tag == 3) {
            if (FX_REC_VARIANT_TAG(v_911) == 19) {
               _fx_N14C_form__ctyp_t elemtyp_2 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_952 = {0};
               _fx_R16Ast__val_flags_t v_953 = {0};
               _fx_N14C_form__cexp_t dst_exp_17 = 0;
               _fx_LN15C_form__cstmt_t ccode_174 = 0;
               _fx_R16Ast__val_flags_t v_954 = {0};
               _fx_N14C_form__cexp_t v_955 = 0;
               _fx_Nt6option1N14C_form__cexp_t v_956 = {0};
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_957 = {0};
               _fx_N14C_form__cexp_t lst_end_0 = 0;
               _fx_LN15C_form__cstmt_t ccode_175 = 0;
               _fx_N14C_form__cexp_t v_958 = 0;
               _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_959 = {0};
               _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_960 = 0;
               FX_CALL(
                  _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(v_911->u.KTypList, &for_loc_0,
                     &elemtyp_2, 0), _fx_catch_214);
               if (unzip_mode_0) {
                  _fx_R9Ast__id_t v_961;
                  fx_str_t slit_203 = FX_MAKE_STR("lst");
                  FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_203, &v_961, 0), _fx_catch_214);
                  FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_953, 0), _fx_catch_214);
                  FX_CALL(
                     _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                        &v_961, coll_ctyp_0, &v_953, &_fx_g18C_gen_code__None2_, ccode_168, &for_loc_0, block_stack_ref_0,
                        &v_952, 0), _fx_catch_214);
               }
               else {
                  fx_str_t slit_204 = FX_MAKE_STR("lst");
                  FX_CALL(
                     _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
                        dstexp_r_0, &slit_204, coll_ctyp_0, ccode_168, &for_loc_0, block_stack_ref_0, km_idx_0, &v_952, 0),
                     _fx_catch_214);
               }
               FX_COPY_PTR(v_952.t0, &dst_exp_17);
               FX_COPY_PTR(v_952.t1, &ccode_174);
               _fx_R9Ast__id_t v_962;
               fx_str_t slit_205 = FX_MAKE_STR("lstend");
               FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_205, &v_962, 0), _fx_catch_214);
               FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_954, 0), _fx_catch_214);
               FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&for_loc_0, &v_955, 0), _fx_catch_214);
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_955, &v_956);
               fx_str_t slit_206 = FX_MAKE_STR("");
               FX_CALL(
                  _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                     &v_962, coll_ctyp_0, &v_954, &slit_206, &v_956, ccode_174, &for_loc_0, &v_957, 0), _fx_catch_214);
               FX_COPY_PTR(v_957.t0, &lst_end_0);
               FX_COPY_PTR(v_957.t1, &ccode_175);
               FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(&for_loc_0, &v_958, 0), _fx_catch_214);
               _fx_make_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(coll_ctyp_0,
                  elemtyp_2, dst_exp_17, v_958, lst_end_0, &v_959);
               FX_CALL(
                  _fx_cons_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_959,
                     dst_data_2, true, &v_960), _fx_catch_214);
               _fx_make_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                  v_960, ccode_175, finalize_ccode_1, &v_912);

            _fx_catch_214: ;
               if (v_960) {
                  _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_960);
               }
               _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_959);
               if (v_958) {
                  _fx_free_N14C_form__cexp_t(&v_958);
               }
               if (ccode_175) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_175);
               }
               if (lst_end_0) {
                  _fx_free_N14C_form__cexp_t(&lst_end_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_957);
               _fx_free_Nt6option1N14C_form__cexp_t(&v_956);
               if (v_955) {
                  _fx_free_N14C_form__cexp_t(&v_955);
               }
               _fx_free_R16Ast__val_flags_t(&v_954);
               if (ccode_174) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_174);
               }
               if (dst_exp_17) {
                  _fx_free_N14C_form__cexp_t(&dst_exp_17);
               }
               _fx_free_R16Ast__val_flags_t(&v_953);
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_952);
               if (elemtyp_2) {
                  _fx_free_N14C_form__ctyp_t(&elemtyp_2);
               }
               goto _fx_endmatch_35;
            }
         }
         fx_str_t maptype_str_0 = {0};
         fx_str_t v_963 = {0};
         fx_str_t v_964 = {0};
         fx_str_t v_965 = {0};
         fx_exn_t v_966 = {0};
         int tag_29 = for_flag_make_0.tag;
         if (tag_29 == 2) {
            fx_str_t slit_207 = FX_MAKE_STR("make_array"); fx_copy_str(&slit_207, &maptype_str_0);
         }
         else if (tag_29 == 3) {
            fx_str_t slit_208 = FX_MAKE_STR("make_list"); fx_copy_str(&slit_208, &maptype_str_0);
         }
         else if (tag_29 == 4) {
            fx_str_t slit_209 = FX_MAKE_STR("make_vector"); fx_copy_str(&slit_209, &maptype_str_0);
         }
         else {
            fx_str_t slit_210 = FX_MAKE_STR("???"); fx_copy_str(&slit_210, &maptype_str_0);
         }
         FX_CHECK_EXN(_fx_catch_215);
         FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&maptype_str_0, &v_963, 0), _fx_catch_215);
         FX_CALL(_fx_M6K_formFM6stringS1N14K_form__ktyp_t(coll_typ_0, &v_964, 0), _fx_catch_215);
         fx_str_t slit_211 = FX_MAKE_STR("cgen: invalid combination of comprehension type \'");
         fx_str_t slit_212 = FX_MAKE_STR("\' and the output collection type \'");
         fx_str_t slit_213 = FX_MAKE_STR("\'");
         {
            const fx_str_t strs_34[] = { slit_211, v_963, slit_212, v_964, slit_213 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_34, 5, &v_965), _fx_catch_215);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_965, &v_966, 0), _fx_catch_215);
         FX_THROW(&v_966, false, _fx_catch_215);

      _fx_catch_215: ;
         fx_free_exn(&v_966);
         FX_FREE_STR(&v_965);
         FX_FREE_STR(&v_964);
         FX_FREE_STR(&v_963);
         FX_FREE_STR(&maptype_str_0);

      _fx_endmatch_35: ;
         FX_CHECK_EXN(_fx_catch_216);
         _fx_free_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            &__fold_result___19);
         _fx_copy_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            &v_912, &__fold_result___19);

      _fx_catch_216: ;
         _fx_free_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            &v_912);
         if (v_911) {
            _fx_free_N14K_form__ktyp_t(&v_911);
         }
         if (coll_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&coll_ctyp_0);
         }
         if (finalize_ccode_1) {
            _fx_free_LN15C_form__cstmt_t(&finalize_ccode_1);
         }
         if (ccode_168) {
            _fx_free_LN15C_form__cstmt_t(&ccode_168);
         }
         if (dst_data_2) {
            _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst_data_2);
         }
         _fx_free_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            &v_910);
         FX_CHECK_EXN(_fx_catch_218);
      }
      _fx_copy_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         &__fold_result___19, &v_886);
      FX_COPY_PTR(v_886.t0, &dst_data_0);
      FX_COPY_PTR(v_886.t1, &ccode_167);
      FX_COPY_PTR(v_886.t2, &finalize_ccode_0);
      FX_CALL(
         _fx_M10C_gen_codeFM3revLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t1LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
            dst_data_0, &dst_data_1, 0), _fx_catch_218);
      _fx_M10C_gen_codeFM7make_fpFPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
         block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &form_map_0);
      _fx_make_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(vcase_23->t1, 0, 0, &v_887);
      FX_CALL(_fx_cons_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_887, 0, true, &v_888), _fx_catch_218);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t2LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
            e_idoml_l_2, v_888, &v_889, 0), _fx_catch_218);
      FX_CALL(
         form_map_0.fp(0, 0, v_889, 0, 0, block_stack_ref_0, decl_nested_status_1, defined_syms_ref_0, dst_data_1,
            &end_for_loc_0, &for_flag_make_0, for_letters_0, &for_loc_0, func_dstexp_r_ref_0, fwd_fdecls_ref_0, fx_status__0,
            glob_data_ccode_ref_0, i2e_ref_0, is_parallel_map_0, &kloc_0, km_idx_0, map_lbl_0, mod_sc_0, module_cleanup_ref_0,
            ndims_3, need_make_array_0, nested_status_1, nfors_0, par_status_1, pre_alloc_array_0, return_used_ref_0,
            top_inline_ccode_ref_0, u1vals_0, unzip_mode_0, &v_890, form_map_0.fcv), _fx_catch_218);
      FX_COPY_PTR(v_890.t0, &pre_map_ccode_0);
      FX_COPY_PTR(v_890.t1, &map_ccode_0);
      if (!is_parallel_map_0) {
         FX_COPY_PTR(map_ccode_0, &map_ccode_1);
      }
      else {
         _fx_R9Ast__id_t v_967;
         fx_str_t slit_214 = FX_MAKE_STR("FX_UPDATE_EXN_PARALLEL");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_214, &v_967, 0), _fx_catch_218);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(map_lbl_0, 0, true, &v_891), _fx_catch_218);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(par_status_1, v_891, false, &v_891), _fx_catch_218);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_967, v_891,
               _fx_g20C_gen_code__CTypVoid, &kloc_0, &update_exn_parallel_0, 0), _fx_catch_218);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(update_exn_parallel_0, &v_892), _fx_catch_218);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_892, map_ccode_0, true, &map_ccode_1), _fx_catch_218);
      }
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(finalize_ccode_0, map_ccode_1,
            &map_ccode_2, 0), _fx_catch_218);
      if (!unzip_mode_0) {
         FX_COPY_PTR(map_ccode_2, &map_ccode_3);
      }
      else {
         _fx_R9Ast__id_t tcon_1;
         FX_CALL(
            _fx_M11C_gen_typesFM15get_constructorR9Ast__id_t3N14C_form__ctyp_tBR10Ast__loc_t(ctyp_0, false, &kloc_0, &tcon_1,
               0), _fx_catch_218);
         _fx_LN14C_form__cexp_t lstend_1 = 0;
         _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t lst_27 = dst_data_1;
         for (; lst_27; lst_27 = lst_27->tl) {
            _fx_N14C_form__cexp_t dst_exp_18 = 0;
            _fx_N14C_form__cexp_t res_23 = 0;
            _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* __pat___9 =
               &lst_27->hd;
            FX_COPY_PTR(__pat___9->t2, &dst_exp_18);
            FX_CALL(
               _fx_M10C_gen_codeFM12make_fun_argN14C_form__cexp_t2N14C_form__cexp_tR10Ast__loc_t(dst_exp_18, &kloc_0, &res_23,
                  0), _fx_catch_217);
            _fx_LN14C_form__cexp_t node_1 = 0;
            FX_CALL(_fx_cons_LN14C_form__cexp_t(res_23, 0, false, &node_1), _fx_catch_217);
            FX_LIST_APPEND(cargs_6, lstend_1, node_1);

         _fx_catch_217: ;
            if (res_23) {
               _fx_free_N14C_form__cexp_t(&res_23);
            }
            if (dst_exp_18) {
               _fx_free_N14C_form__cexp_t(&dst_exp_18);
            }
            FX_CHECK_EXN(_fx_catch_218);
         }
         fx_str_t slit_215 = FX_MAKE_STR("tup");
         FX_CALL(
            _fx_M10C_gen_codeFM10get_dstexpT2N14C_form__cexp_tLN15C_form__cstmt_t7rNt6option1N14C_form__cexp_tSN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_ti(
               dstexp_r_0, &slit_215, ctyp_0, map_ccode_2, &kloc_0, block_stack_ref_0, km_idx_0, &v_893, 0), _fx_catch_218);
         FX_COPY_PTR(v_893.t0, &t_exp_2);
         FX_COPY_PTR(v_893.t1, &map_ccode_4);
         FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(t_exp_2, &v_894, 0), _fx_catch_218);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_894, 0, true, &v_895), _fx_catch_218);
         FX_CALL(_fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(cargs_6, v_895, &v_896, 0),
            _fx_catch_218);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&tcon_1,
               v_896, _fx_g20C_gen_code__CTypVoid, &kloc_0, &call_mktup_1, 0), _fx_catch_218);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(call_mktup_1, &v_897), _fx_catch_218);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_897, map_ccode_4, true, &map_ccode_3), _fx_catch_218);
      }
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(pre_map_ccode_0, ccode_167,
            &v_898, 0), _fx_catch_218);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(map_ccode_3, v_898, &v_899, 0),
         _fx_catch_218);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_899, &v_1);

   _fx_catch_218: ;
      if (v_899) {
         _fx_free_LN15C_form__cstmt_t(&v_899);
      }
      if (v_898) {
         _fx_free_LN15C_form__cstmt_t(&v_898);
      }
      if (v_897) {
         _fx_free_N15C_form__cstmt_t(&v_897);
      }
      if (call_mktup_1) {
         _fx_free_N14C_form__cexp_t(&call_mktup_1);
      }
      if (v_896) {
         _fx_free_LN14C_form__cexp_t(&v_896);
      }
      if (v_895) {
         _fx_free_LN14C_form__cexp_t(&v_895);
      }
      if (v_894) {
         _fx_free_N14C_form__cexp_t(&v_894);
      }
      if (map_ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&map_ccode_4);
      }
      if (t_exp_2) {
         _fx_free_N14C_form__cexp_t(&t_exp_2);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_893);
      if (cargs_6) {
         _fx_free_LN14C_form__cexp_t(&cargs_6);
      }
      if (map_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&map_ccode_3);
      }
      if (map_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&map_ccode_2);
      }
      if (v_892) {
         _fx_free_N15C_form__cstmt_t(&v_892);
      }
      if (update_exn_parallel_0) {
         _fx_free_N14C_form__cexp_t(&update_exn_parallel_0);
      }
      if (v_891) {
         _fx_free_LN14C_form__cexp_t(&v_891);
      }
      if (map_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&map_ccode_1);
      }
      if (map_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&map_ccode_0);
      }
      if (pre_map_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&pre_map_ccode_0);
      }
      _fx_free_Ta2LN15C_form__cstmt_t(&v_890);
      if (v_889) {
         _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_889);
      }
      if (v_888) {
         _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_888);
      }
      _fx_free_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_887);
      FX_FREE_FP(&form_map_0);
      if (dst_data_1) {
         _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst_data_1);
      }
      if (finalize_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&finalize_ccode_0);
      }
      if (ccode_167) {
         _fx_free_LN15C_form__cstmt_t(&ccode_167);
      }
      if (dst_data_0) {
         _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst_data_0);
      }
      _fx_free_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         &v_886);
      _fx_free_T3LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         &__fold_result___19);
      if (coll_typs_0) {
         _fx_free_LN14K_form__ktyp_t(&coll_typs_0);
      }
      if (v_885) {
         _fx_free_N14K_form__ktyp_t(&v_885);
      }
      if (decl_nested_status_1) {
         _fx_free_LN15C_form__cstmt_t(&decl_nested_status_1);
      }
      if (nested_status_1) {
         _fx_free_N14C_form__cexp_t(&nested_status_1);
      }
      if (ccode_166) {
         _fx_free_LN15C_form__cstmt_t(&ccode_166);
      }
      if (par_status_1) {
         _fx_free_N14C_form__cexp_t(&par_status_1);
      }
      if (v_884) {
         _fx_free_N14C_form__cexp_t(&v_884);
      }
      if (decl_nested_status_0) {
         _fx_free_LN15C_form__cstmt_t(&decl_nested_status_0);
      }
      if (nested_status_0) {
         _fx_free_N14C_form__cexp_t(&nested_status_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_883);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_882);
      if (v_881) {
         _fx_free_N14C_form__cexp_t(&v_881);
      }
      _fx_free_R16Ast__val_flags_t(&v_880);
      if (ccode_165) {
         _fx_free_LN15C_form__cstmt_t(&ccode_165);
      }
      if (par_status_0) {
         _fx_free_N14C_form__cexp_t(&par_status_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_879);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_878);
      if (v_877) {
         _fx_free_N14C_form__cexp_t(&v_877);
      }
      _fx_free_R16Ast__val_flags_t(&v_876);
      _fx_free_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(&v_875);
      if (glob_status_0) {
         _fx_free_N14C_form__cexp_t(&glob_status_0);
      }
      if (e_idoml_l_1) {
         _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&e_idoml_l_1);
      }
      if (e_idoml_l_0) {
         _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&e_idoml_l_0);
      }
      if (decl_inside_for_0) {
         _fx_free_Nt10Hashset__t1R9Ast__id_t(&decl_inside_for_0);
      }
      if (map_lbl_0) {
         _fx_free_N14C_form__cexp_t(&map_lbl_0);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 27) {
      _fx_N14C_form__cexp_t lbl_7 = 0;
      _fx_N14C_form__cexp_t glob_status_1 = 0;
      _fx_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t v_968 = {0};
      _fx_R16Ast__val_flags_t v_969 = {0};
      _fx_N14C_form__cexp_t v_970 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_971 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_972 = {0};
      _fx_N14C_form__cexp_t par_status_2 = 0;
      _fx_LN15C_form__cstmt_t ccode_176 = 0;
      _fx_R16Ast__val_flags_t v_973 = {0};
      _fx_N14C_form__cexp_t v_974 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_975 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_976 = {0};
      _fx_N14C_form__cexp_t nested_status_2 = 0;
      _fx_LN15C_form__cstmt_t decl_nested_status_2 = 0;
      _fx_N14C_form__cexp_t v_977 = 0;
      _fx_N14C_form__cexp_t par_status_3 = 0;
      _fx_LN15C_form__cstmt_t ccode_177 = 0;
      _fx_N14C_form__cexp_t nested_status_3 = 0;
      _fx_LN15C_form__cstmt_t decl_nested_status_3 = 0;
      _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_978 = {0};
      _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t v_979 = 0;
      _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t
         v_980 = {0};
      _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t for_headers_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_178 = 0;
      _fx_LN15C_form__cstmt_t pre_body_ccode_0 = 0;
      _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t body_elems_0 = 0;
      _fx_LN15C_form__cstmt_t post_ccode_0 = 0;
      _fx_LN15C_form__cstmt_t body_ccode_0 = 0;
      _fx_LN15C_form__cstmt_t body_ccode_1 = 0;
      _fx_rNt6option1N14C_form__cexp_t v_981 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_982 = {0};
      _fx_LN15C_form__cstmt_t body_ccode_2 = 0;
      _fx_T2R9Ast__id_tN15C_form__cstmt_t v_983 = {0};
      _fx_N15C_form__cstmt_t body_stmt_0 = 0;
      _fx_N15C_form__cstmt_t __fold_result___23 = 0;
      _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_984 = 0;
      _fx_N15C_form__cstmt_t for_stmt_0 = 0;
      _fx_LN15C_form__cstmt_t post_ccode_1 = 0;
      _fx_N15C_form__cstmt_t v_985 = 0;
      _fx_Ta2LN15C_form__cstmt_t v_986 = {0};
      _fx_LN14C_form__cexp_t v_987 = 0;
      _fx_N14C_form__cexp_t update_exn_parallel_1 = 0;
      _fx_N15C_form__cstmt_t v_988 = 0;
      _fx_LN15C_form__cstmt_t v_989 = 0;
      _fx_N15C_form__cstmt_t v_990 = 0;
      _fx_LN15C_form__cstmt_t v_991 = 0;
      _fx_LN15C_form__cstmt_t omp_pragma_0 = 0;
      _fx_LN15C_form__cstmt_t post_ccode_2 = 0;
      _fx_LN15C_form__cstmt_t v_992 = 0;
      _fx_LN15C_form__cstmt_t v_993 = 0;
      _fx_LN15C_form__cstmt_t v_994 = 0;
      _fx_LN15C_form__cstmt_t v_995 = 0;
      _fx_T5LT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tN14K_form__kexp_tR16Ast__for_flags_tR10Ast__loc_t* vcase_26 =
         &kexp_0->u.KExpFor;
      _fx_R16Ast__for_flags_t* flags_1 = &vcase_26->t3;
      _fx_N14K_form__kexp_t body_0 = vcase_26->t2;
      _fx_LT2R9Ast__id_tN13K_form__dom_t idoml_2 = vcase_26->t0;
      FX_CALL(
         _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &lbl_7, 0), _fx_catch_220);
      _fx_R10Ast__loc_t for_loc_1;
      FX_CALL(_fx_M3AstFM13get_start_locRM5loc_t1RM5loc_t(&kloc_0, &for_loc_1, 0), _fx_catch_220);
      _fx_R10Ast__loc_t end_for_loc_1;
      FX_CALL(_fx_M3AstFM11get_end_locRM5loc_t1RM5loc_t(&kloc_0, &end_for_loc_1, 0), _fx_catch_220);
      int_ ndims_4;
      FX_CALL(
         _fx_M10C_gen_codeFM17compute_for_ndimsi4iiLT2R9Ast__id_tN13K_form__dom_tR10Ast__loc_t(0, 1, idoml_2, &for_loc_1,
            &ndims_4, 0), _fx_catch_220);
      FX_CALL(
         _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(fx_status__0,
            _fx_g20C_gen_code__CTypCInt, &kloc_0, &glob_status_1, 0), _fx_catch_220);
      bool is_parallel_for_0 = flags_1->for_flag_parallel;
      if (is_parallel_for_0) {
         _fx_R9Ast__id_t v_996;
         fx_str_t slit_216 = FX_MAKE_STR("par_status");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_216, &v_996, 0), _fx_catch_220);
         FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_969, 0), _fx_catch_220);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_970, 0), _fx_catch_220);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_970, &v_971);
         fx_str_t slit_217 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_996, _fx_g20C_gen_code__CTypCInt, &v_969, &slit_217, &v_971, ccode_0, &kloc_0, &v_972, 0), _fx_catch_220);
         FX_COPY_PTR(v_972.t0, &par_status_2);
         FX_COPY_PTR(v_972.t1, &ccode_176);
         _fx_R9Ast__id_t v_997;
         fx_str_t slit_218 = FX_MAKE_STR("status");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_218, &v_997, 0), _fx_catch_220);
         FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_973, 0), _fx_catch_220);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kloc_0, &v_974, 0), _fx_catch_220);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_974, &v_975);
         fx_str_t slit_219 = FX_MAKE_STR("fx_status");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_997, _fx_g20C_gen_code__CTypCInt, &v_973, &slit_219, &v_975, 0, &kloc_0, &v_976, 0), _fx_catch_220);
         FX_COPY_PTR(v_976.t0, &nested_status_2);
         FX_COPY_PTR(v_976.t1, &decl_nested_status_2);
         _fx_make_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(par_status_2, ccode_176,
            nested_status_2, decl_nested_status_2, &v_968);
      }
      else {
         FX_CALL(_fx_M6C_formFM14make_dummy_expN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_977, 0), _fx_catch_220);
         _fx_make_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(v_977, ccode_0, glob_status_1, 0,
            &v_968);
      }
      FX_COPY_PTR(v_968.t0, &par_status_3);
      FX_COPY_PTR(v_968.t1, &ccode_177);
      FX_COPY_PTR(v_968.t2, &nested_status_3);
      FX_COPY_PTR(v_968.t3, &decl_nested_status_3);
      _fx_make_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(body_0, 0, 0, &v_978);
      FX_CALL(_fx_cons_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_978, 0, true, &v_979), _fx_catch_220);
      FX_CALL(
         process_for_0.fp(lbl_7, idoml_2, vcase_26->t1, 0, 1, ndims_4, 0, v_979, ccode_177, &kloc_0, block_stack_ref_0,
            defined_syms_ref_0, for_letters_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_980, process_for_0.fcv),
         _fx_catch_220);
      FX_COPY_PTR(v_980.t0, &for_headers_0);
      FX_COPY_PTR(v_980.t4, &ccode_178);
      FX_COPY_PTR(v_980.t5, &pre_body_ccode_0);
      FX_COPY_PTR(v_980.t6, &body_elems_0);
      FX_COPY_PTR(v_980.t7, &post_ccode_0);
      FX_CALL(
         _fx_M10C_gen_codeFM17new_for_block_ctxv7iR16Ast__for_flags_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_trLrRM11block_ctx_ti(
            ndims_4, flags_1, nested_status_3, par_status_3, &kloc_0, block_stack_ref_0, km_idx_0, 0), _fx_catch_220);
      if (is_parallel_for_0) {
         FX_COPY_PTR(decl_nested_status_3, &body_ccode_0);
      }
      FX_CALL(
         _fx_M10C_gen_codeFM19decl_for_body_elemsLN15C_form__cstmt_t4LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
            body_elems_0, body_ccode_0, block_stack_ref_0, i2e_ref_0, &body_ccode_1, 0), _fx_catch_220);
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_981), _fx_catch_220);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            body_0, v_981, body_ccode_1, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_982, fx_fv), _fx_catch_220);
      FX_COPY_PTR(v_982.t1, &body_ccode_2);
      _fx_R10Ast__loc_t body_loc_0;
      FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(body_0, &body_loc_0, 0), _fx_catch_220);
      FX_CALL(
         _fx_M10C_gen_codeFM18finalize_loop_bodyT2R9Ast__id_tN15C_form__cstmt_t4LN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_t(
            body_ccode_2, true, &body_loc_0, block_stack_ref_0, &v_983, 0), _fx_catch_220);
      _fx_R9Ast__id_t br_label_0 = v_983.t0;
      FX_COPY_PTR(v_983.t1, &body_stmt_0);
      FX_COPY_PTR(body_stmt_0, &__fold_result___23);
      FX_CALL(
         _fx_M10C_gen_codeFM3revLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
            for_headers_0, &v_984, 0), _fx_catch_220);
      int_ k_0 = 0;
      _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t lst_28 = v_984;
      for (; lst_28; lst_28 = lst_28->tl, k_0 += 1) {
         _fx_Nt6option1N14C_form__ctyp_t t_opt_0 = {0};
         _fx_LN14C_form__cexp_t for_inits_0 = 0;
         _fx_Nt6option1N14C_form__cexp_t for_check_opt_0 = {0};
         _fx_LN14C_form__cexp_t for_incrs_0 = 0;
         _fx_N15C_form__cstmt_t for_stmt_1 = 0;
         _fx_N15C_form__cstmt_t for_stmt_2 = 0;
         _fx_N15C_form__cstmt_t v_998 = 0;
         _fx_LN15C_form__cstmt_t v_999 = 0;
         _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* __pat___10 =
            &lst_28->hd;
         _fx_copy_Nt6option1N14C_form__ctyp_t(&__pat___10->t0, &t_opt_0);
         FX_COPY_PTR(__pat___10->t1, &for_inits_0);
         _fx_copy_Nt6option1N14C_form__cexp_t(&__pat___10->t2, &for_check_opt_0);
         FX_COPY_PTR(__pat___10->t3, &for_incrs_0);
         FX_COPY_PTR(__fold_result___23, &for_stmt_1);
         FX_CALL(
            _fx_M6C_formFM8CStmtForN15C_form__cstmt_t6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
               &t_opt_0, for_inits_0, &for_check_opt_0, for_incrs_0, for_stmt_1, &kloc_0, &for_stmt_2), _fx_catch_219);
         bool t_14;
         if (k_0 > 0) {
            t_14 = true;
         }
         else {
            t_14 = pre_body_ccode_0 == 0;
         }
         if (t_14) {
            FX_COPY_PTR(for_stmt_2, &v_998);
         }
         else {
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(for_stmt_2, pre_body_ccode_0, true, &v_999), _fx_catch_219);
            FX_CALL(
               _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(v_999, &for_loc_1, &v_998, 0),
               _fx_catch_219);
         }
         _fx_free_N15C_form__cstmt_t(&__fold_result___23);
         FX_COPY_PTR(v_998, &__fold_result___23);

      _fx_catch_219: ;
         if (v_999) {
            _fx_free_LN15C_form__cstmt_t(&v_999);
         }
         if (v_998) {
            _fx_free_N15C_form__cstmt_t(&v_998);
         }
         if (for_stmt_2) {
            _fx_free_N15C_form__cstmt_t(&for_stmt_2);
         }
         if (for_stmt_1) {
            _fx_free_N15C_form__cstmt_t(&for_stmt_1);
         }
         if (for_incrs_0) {
            _fx_free_LN14C_form__cexp_t(&for_incrs_0);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&for_check_opt_0);
         if (for_inits_0) {
            _fx_free_LN14C_form__cexp_t(&for_inits_0);
         }
         _fx_free_Nt6option1N14C_form__ctyp_t(&t_opt_0);
         FX_CHECK_EXN(_fx_catch_220);
      }
      FX_COPY_PTR(__fold_result___23, &for_stmt_0);
      bool res_24;
      FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&br_label_0, &_fx_g9Ast__noid, &res_24, 0), _fx_catch_220);
      if (res_24) {
         FX_COPY_PTR(post_ccode_0, &post_ccode_1);
      }
      else {
         FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&br_label_0, &end_for_loc_1, &v_985),
            _fx_catch_220);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_985, post_ccode_0, true, &post_ccode_1), _fx_catch_220);
      }
      if (!is_parallel_for_0) {
         _fx_make_Ta2LN15C_form__cstmt_t(0, post_ccode_1, &v_986);
      }
      else {
         _fx_R9Ast__id_t v_1000;
         fx_str_t slit_220 = FX_MAKE_STR("FX_UPDATE_EXN_PARALLEL");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_220, &v_1000, 0), _fx_catch_220);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_7, 0, true, &v_987), _fx_catch_220);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(par_status_3, v_987, false, &v_987), _fx_catch_220);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_1000,
               v_987, _fx_g20C_gen_code__CTypVoid, &kloc_0, &update_exn_parallel_1, 0), _fx_catch_220);
         fx_str_t slit_221 = FX_MAKE_STR("omp parallel for");
         FX_CALL(_fx_M6C_formFM12CMacroPragmaN15C_form__cstmt_t2SR10Ast__loc_t(&slit_221, &kloc_0, &v_988), _fx_catch_220);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_988, 0, true, &v_989), _fx_catch_220);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(update_exn_parallel_1, &v_990), _fx_catch_220);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_990, post_ccode_1, true, &v_991), _fx_catch_220);
         _fx_make_Ta2LN15C_form__cstmt_t(v_989, v_991, &v_986);
      }
      FX_COPY_PTR(v_986.t0, &omp_pragma_0);
      FX_COPY_PTR(v_986.t1, &post_ccode_2);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(for_stmt_0, 0, true, &v_992), _fx_catch_220);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(omp_pragma_0, ccode_178, &v_993,
            0), _fx_catch_220);
      FX_CALL(_fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_992, v_993, &v_994, 0),
         _fx_catch_220);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(post_ccode_2, v_994, &v_995, 0),
         _fx_catch_220);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_995, &v_1);

   _fx_catch_220: ;
      if (v_995) {
         _fx_free_LN15C_form__cstmt_t(&v_995);
      }
      if (v_994) {
         _fx_free_LN15C_form__cstmt_t(&v_994);
      }
      if (v_993) {
         _fx_free_LN15C_form__cstmt_t(&v_993);
      }
      if (v_992) {
         _fx_free_LN15C_form__cstmt_t(&v_992);
      }
      if (post_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&post_ccode_2);
      }
      if (omp_pragma_0) {
         _fx_free_LN15C_form__cstmt_t(&omp_pragma_0);
      }
      if (v_991) {
         _fx_free_LN15C_form__cstmt_t(&v_991);
      }
      if (v_990) {
         _fx_free_N15C_form__cstmt_t(&v_990);
      }
      if (v_989) {
         _fx_free_LN15C_form__cstmt_t(&v_989);
      }
      if (v_988) {
         _fx_free_N15C_form__cstmt_t(&v_988);
      }
      if (update_exn_parallel_1) {
         _fx_free_N14C_form__cexp_t(&update_exn_parallel_1);
      }
      if (v_987) {
         _fx_free_LN14C_form__cexp_t(&v_987);
      }
      _fx_free_Ta2LN15C_form__cstmt_t(&v_986);
      if (v_985) {
         _fx_free_N15C_form__cstmt_t(&v_985);
      }
      if (post_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&post_ccode_1);
      }
      if (for_stmt_0) {
         _fx_free_N15C_form__cstmt_t(&for_stmt_0);
      }
      if (v_984) {
         _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_984);
      }
      if (__fold_result___23) {
         _fx_free_N15C_form__cstmt_t(&__fold_result___23);
      }
      if (body_stmt_0) {
         _fx_free_N15C_form__cstmt_t(&body_stmt_0);
      }
      _fx_free_T2R9Ast__id_tN15C_form__cstmt_t(&v_983);
      if (body_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_2);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_982);
      if (v_981) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_981);
      }
      if (body_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_1);
      }
      if (body_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_0);
      }
      if (post_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&post_ccode_0);
      }
      if (body_elems_0) {
         _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&body_elems_0);
      }
      if (pre_body_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_0);
      }
      if (ccode_178) {
         _fx_free_LN15C_form__cstmt_t(&ccode_178);
      }
      if (for_headers_0) {
         _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&for_headers_0);
      }
      _fx_free_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t(
         &v_980);
      if (v_979) {
         _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_979);
      }
      _fx_free_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&v_978);
      if (decl_nested_status_3) {
         _fx_free_LN15C_form__cstmt_t(&decl_nested_status_3);
      }
      if (nested_status_3) {
         _fx_free_N14C_form__cexp_t(&nested_status_3);
      }
      if (ccode_177) {
         _fx_free_LN15C_form__cstmt_t(&ccode_177);
      }
      if (par_status_3) {
         _fx_free_N14C_form__cexp_t(&par_status_3);
      }
      if (v_977) {
         _fx_free_N14C_form__cexp_t(&v_977);
      }
      if (decl_nested_status_2) {
         _fx_free_LN15C_form__cstmt_t(&decl_nested_status_2);
      }
      if (nested_status_2) {
         _fx_free_N14C_form__cexp_t(&nested_status_2);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_976);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_975);
      if (v_974) {
         _fx_free_N14C_form__cexp_t(&v_974);
      }
      _fx_free_R16Ast__val_flags_t(&v_973);
      if (ccode_176) {
         _fx_free_LN15C_form__cstmt_t(&ccode_176);
      }
      if (par_status_2) {
         _fx_free_N14C_form__cexp_t(&par_status_2);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_972);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_971);
      if (v_970) {
         _fx_free_N14C_form__cexp_t(&v_970);
      }
      _fx_free_R16Ast__val_flags_t(&v_969);
      _fx_free_T4N14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tLN15C_form__cstmt_t(&v_968);
      if (glob_status_1) {
         _fx_free_N14C_form__cexp_t(&glob_status_1);
      }
      if (lbl_7) {
         _fx_free_N14C_form__cexp_t(&lbl_7);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 28) {
      _fx_rNt6option1N14C_form__cexp_t v_1001 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1002 = {0};
      _fx_N14C_form__cexp_t cc_1 = 0;
      _fx_LN15C_form__cstmt_t cc_code_0 = 0;
      _fx_T2BLN15C_form__cstmt_t v_1003 = {0};
      _fx_LN15C_form__cstmt_t check_code_0 = 0;
      _fx_rNt6option1N14C_form__cexp_t v_1004 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1005 = {0};
      _fx_LN15C_form__cstmt_t body_ccode_3 = 0;
      _fx_LN15C_form__cstmt_t body_ccode_4 = 0;
      _fx_T2R9Ast__id_tN15C_form__cstmt_t v_1006 = {0};
      _fx_N15C_form__cstmt_t body_stmt_1 = 0;
      _fx_N15C_form__cstmt_t loop_stmt_0 = 0;
      _fx_LN15C_form__cstmt_t v_1007 = 0;
      _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t* vcase_27 = &kexp_0->u.KExpWhile;
      FX_CALL(
         _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
            &_fx_g26C_gen_code__BlockKind_Loop, &kloc_0, block_stack_ref_0, km_idx_0, 0), _fx_catch_222);
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1001), _fx_catch_222);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            vcase_27->t0, v_1001, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1002, fx_fv), _fx_catch_222);
      FX_COPY_PTR(v_1002.t0, &cc_1);
      FX_COPY_PTR(v_1002.t1, &cc_code_0);
      if (cc_code_0 == 0) {
         if (FX_REC_VARIANT_TAG(cc_1) == 2) {
            _fx_N14K_form__klit_t* v_1008 = &cc_1->u.CExpLit.t0;
            if (v_1008->tag == 7) {
               if (v_1008->u.KLitBool == true) {
                  _fx_make_T2BLN15C_form__cstmt_t(true, 0, &v_1003); goto _fx_endmatch_36;
               }
            }
         }
      }
      if (cc_code_0 == 0) {
         _fx_make_T2BLN15C_form__cstmt_t(false, 0, &v_1003); goto _fx_endmatch_36;
      }
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1009 = {0};
      _fx_N14C_form__cexp_t not_cc_0 = 0;
      _fx_N15C_form__cstmt_t break_stmt_1 = 0;
      _fx_N15C_form__cstmt_t v_1010 = 0;
      _fx_N15C_form__cstmt_t check_cc_0 = 0;
      _fx_LN15C_form__cstmt_t v_1011 = 0;
      _fx_R10Ast__loc_t cc_loc_0;
      FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(cc_1, &cc_loc_0, 0), _fx_catch_221);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &cc_loc_0, &v_1009);
      FX_CALL(
         _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g23C_gen_code__COpLogicNot, cc_1, &v_1009, &not_cc_0), _fx_catch_221);
      FX_CALL(
         _fx_M10C_gen_codeFM15make_break_stmtN15C_form__cstmt_t2R10Ast__loc_trLrRM11block_ctx_t(&cc_loc_0, block_stack_ref_0,
            &break_stmt_1, 0), _fx_catch_221);
      FX_CALL(_fx_M6C_formFM8CStmtNopN15C_form__cstmt_t1R10Ast__loc_t(&cc_loc_0, &v_1010), _fx_catch_221);
      FX_CALL(
         _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
            not_cc_0, break_stmt_1, v_1010, &cc_loc_0, &check_cc_0, 0), _fx_catch_221);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(check_cc_0, cc_code_0, true, &v_1011), _fx_catch_221);
      _fx_make_T2BLN15C_form__cstmt_t(true, v_1011, &v_1003);

   _fx_catch_221: ;
      if (v_1011) {
         _fx_free_LN15C_form__cstmt_t(&v_1011);
      }
      if (check_cc_0) {
         _fx_free_N15C_form__cstmt_t(&check_cc_0);
      }
      if (v_1010) {
         _fx_free_N15C_form__cstmt_t(&v_1010);
      }
      if (break_stmt_1) {
         _fx_free_N15C_form__cstmt_t(&break_stmt_1);
      }
      if (not_cc_0) {
         _fx_free_N14C_form__cexp_t(&not_cc_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1009);

   _fx_endmatch_36: ;
      FX_CHECK_EXN(_fx_catch_222);
      bool is_for_loop_0 = v_1003.t0;
      FX_COPY_PTR(v_1003.t1, &check_code_0);
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1004), _fx_catch_222);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            vcase_27->t1, v_1004, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1005, fx_fv), _fx_catch_222);
      FX_COPY_PTR(v_1005.t1, &body_ccode_3);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(body_ccode_3, check_code_0,
            &body_ccode_4, 0), _fx_catch_222);
      FX_CALL(
         _fx_M10C_gen_codeFM18finalize_loop_bodyT2R9Ast__id_tN15C_form__cstmt_t4LN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_t(
            body_ccode_4, true, &kloc_0, block_stack_ref_0, &v_1006, 0), _fx_catch_222);
      FX_COPY_PTR(v_1006.t1, &body_stmt_1);
      if (is_for_loop_0) {
         FX_CALL(
            _fx_M6C_formFM8CStmtForN15C_form__cstmt_t6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
               &_fx_g18C_gen_code__None1_, 0, &_fx_g18C_gen_code__None2_, 0, body_stmt_1, &kloc_0, &loop_stmt_0),
            _fx_catch_222);
      }
      else {
         FX_CALL(
            _fx_M6C_formFM10CStmtWhileN15C_form__cstmt_t3N14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(cc_1, body_stmt_1,
               &kloc_0, &loop_stmt_0), _fx_catch_222);
      }
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(loop_stmt_0, ccode_0, true, &v_1007), _fx_catch_222);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_1007, &v_1);

   _fx_catch_222: ;
      if (v_1007) {
         _fx_free_LN15C_form__cstmt_t(&v_1007);
      }
      if (loop_stmt_0) {
         _fx_free_N15C_form__cstmt_t(&loop_stmt_0);
      }
      if (body_stmt_1) {
         _fx_free_N15C_form__cstmt_t(&body_stmt_1);
      }
      _fx_free_T2R9Ast__id_tN15C_form__cstmt_t(&v_1006);
      if (body_ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_4);
      }
      if (body_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_3);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1005);
      if (v_1004) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1004);
      }
      if (check_code_0) {
         _fx_free_LN15C_form__cstmt_t(&check_code_0);
      }
      _fx_free_T2BLN15C_form__cstmt_t(&v_1003);
      if (cc_code_0) {
         _fx_free_LN15C_form__cstmt_t(&cc_code_0);
      }
      if (cc_1) {
         _fx_free_N14C_form__cexp_t(&cc_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1002);
      if (v_1001) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1001);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 29) {
      _fx_rNt6option1N14C_form__cexp_t v_1012 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1013 = {0};
      _fx_LN15C_form__cstmt_t body_ccode_5 = 0;
      _fx_rNt6option1N14C_form__cexp_t v_1014 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1015 = {0};
      _fx_N14C_form__cexp_t cc_2 = 0;
      _fx_LN15C_form__cstmt_t cc_code_1 = 0;
      _fx_T2BLN15C_form__cstmt_t v_1016 = {0};
      _fx_LN15C_form__cstmt_t check_code_1 = 0;
      _fx_LN15C_form__cstmt_t body_ccode_6 = 0;
      _fx_T2R9Ast__id_tN15C_form__cstmt_t v_1017 = {0};
      _fx_N15C_form__cstmt_t body_stmt_2 = 0;
      _fx_N15C_form__cstmt_t loop_stmt_1 = 0;
      _fx_LN15C_form__cstmt_t v_1018 = 0;
      _fx_T3N14K_form__kexp_tN14K_form__kexp_tR10Ast__loc_t* vcase_28 = &kexp_0->u.KExpDoWhile;
      FX_CALL(
         _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(
            &_fx_g26C_gen_code__BlockKind_Loop, &kloc_0, block_stack_ref_0, km_idx_0, 0), _fx_catch_224);
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1012), _fx_catch_224);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            vcase_28->t0, v_1012, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1013, fx_fv), _fx_catch_224);
      FX_COPY_PTR(v_1013.t1, &body_ccode_5);
      FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1014), _fx_catch_224);
      FX_CALL(
         _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
            vcase_28->t1, v_1014, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
            fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
            return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1015, fx_fv), _fx_catch_224);
      FX_COPY_PTR(v_1015.t0, &cc_2);
      FX_COPY_PTR(v_1015.t1, &cc_code_1);
      if (cc_code_1 == 0) {
         if (FX_REC_VARIANT_TAG(cc_2) == 2) {
            _fx_N14K_form__klit_t* v_1019 = &cc_2->u.CExpLit.t0;
            if (v_1019->tag == 7) {
               if (v_1019->u.KLitBool == true) {
                  _fx_make_T2BLN15C_form__cstmt_t(true, 0, &v_1016); goto _fx_endmatch_37;
               }
            }
         }
      }
      if (cc_code_1 == 0) {
         _fx_make_T2BLN15C_form__cstmt_t(false, 0, &v_1016); goto _fx_endmatch_37;
      }
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1020 = {0};
      _fx_N14C_form__cexp_t not_cc_1 = 0;
      _fx_N15C_form__cstmt_t break_stmt_2 = 0;
      _fx_N15C_form__cstmt_t v_1021 = 0;
      _fx_N15C_form__cstmt_t check_cc_1 = 0;
      _fx_LN15C_form__cstmt_t v_1022 = 0;
      _fx_R10Ast__loc_t cc_loc_1;
      FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(cc_2, &cc_loc_1, 0), _fx_catch_223);
      _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &cc_loc_1, &v_1020);
      FX_CALL(
         _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
            &_fx_g23C_gen_code__COpLogicNot, cc_2, &v_1020, &not_cc_1), _fx_catch_223);
      FX_CALL(
         _fx_M10C_gen_codeFM15make_break_stmtN15C_form__cstmt_t2R10Ast__loc_trLrRM11block_ctx_t(&cc_loc_1, block_stack_ref_0,
            &break_stmt_2, 0), _fx_catch_223);
      FX_CALL(_fx_M6C_formFM8CStmtNopN15C_form__cstmt_t1R10Ast__loc_t(&cc_loc_1, &v_1021), _fx_catch_223);
      FX_CALL(
         _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
            not_cc_1, break_stmt_2, v_1021, &cc_loc_1, &check_cc_1, 0), _fx_catch_223);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(check_cc_1, cc_code_1, true, &v_1022), _fx_catch_223);
      _fx_make_T2BLN15C_form__cstmt_t(true, v_1022, &v_1016);

   _fx_catch_223: ;
      if (v_1022) {
         _fx_free_LN15C_form__cstmt_t(&v_1022);
      }
      if (check_cc_1) {
         _fx_free_N15C_form__cstmt_t(&check_cc_1);
      }
      if (v_1021) {
         _fx_free_N15C_form__cstmt_t(&v_1021);
      }
      if (break_stmt_2) {
         _fx_free_N15C_form__cstmt_t(&break_stmt_2);
      }
      if (not_cc_1) {
         _fx_free_N14C_form__cexp_t(&not_cc_1);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1020);

   _fx_endmatch_37: ;
      FX_CHECK_EXN(_fx_catch_224);
      bool is_for_loop_1 = v_1016.t0;
      FX_COPY_PTR(v_1016.t1, &check_code_1);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(check_code_1, body_ccode_5,
            &body_ccode_6, 0), _fx_catch_224);
      FX_CALL(
         _fx_M10C_gen_codeFM18finalize_loop_bodyT2R9Ast__id_tN15C_form__cstmt_t4LN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_t(
            body_ccode_6, true, &kloc_0, block_stack_ref_0, &v_1017, 0), _fx_catch_224);
      FX_COPY_PTR(v_1017.t1, &body_stmt_2);
      if (is_for_loop_1) {
         FX_CALL(
            _fx_M6C_formFM8CStmtForN15C_form__cstmt_t6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
               &_fx_g18C_gen_code__None1_, 0, &_fx_g18C_gen_code__None2_, 0, body_stmt_2, &kloc_0, &loop_stmt_1),
            _fx_catch_224);
      }
      else {
         FX_CALL(
            _fx_M6C_formFM12CStmtDoWhileN15C_form__cstmt_t3N15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(body_stmt_2, cc_2,
               &kloc_0, &loop_stmt_1), _fx_catch_224);
      }
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(loop_stmt_1, ccode_0, true, &v_1018), _fx_catch_224);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, v_1018, &v_1);

   _fx_catch_224: ;
      if (v_1018) {
         _fx_free_LN15C_form__cstmt_t(&v_1018);
      }
      if (loop_stmt_1) {
         _fx_free_N15C_form__cstmt_t(&loop_stmt_1);
      }
      if (body_stmt_2) {
         _fx_free_N15C_form__cstmt_t(&body_stmt_2);
      }
      _fx_free_T2R9Ast__id_tN15C_form__cstmt_t(&v_1017);
      if (body_ccode_6) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_6);
      }
      if (check_code_1) {
         _fx_free_LN15C_form__cstmt_t(&check_code_1);
      }
      _fx_free_T2BLN15C_form__cstmt_t(&v_1016);
      if (cc_code_1) {
         _fx_free_LN15C_form__cstmt_t(&cc_code_1);
      }
      if (cc_2) {
         _fx_free_N14C_form__cexp_t(&cc_2);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1015);
      if (v_1014) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1014);
      }
      if (body_ccode_5) {
         _fx_free_LN15C_form__cstmt_t(&body_ccode_5);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1013);
      if (v_1012) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1012);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 30) {
      _fx_rR23C_gen_code__block_ctx_t v_1023 = 0;
      fx_exn_t v_1024 = {0};
      _fx_N14C_form__cexp_t v_1025 = 0;
      _fx_N15C_form__cstmt_t v_1026 = 0;
      _fx_LN15C_form__cstmt_t v_1027 = 0;
      FX_CALL(
         _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &v_1023, 0), _fx_catch_225);
      _fx_N24C_gen_code__block_kind_t v_1028 = v_1023->data.bctx_kind;
      if (v_1028.tag != 1) {
         fx_str_t slit_222 = FX_MAKE_STR("cgen: unexpected ccode expression");
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &slit_222, &v_1024, 0), _fx_catch_225);
         FX_THROW(&v_1024, false, _fx_catch_225);
      }
      FX_CALL(_fx_M6C_formFM9CExpCCodeN14C_form__cexp_t2SR10Ast__loc_t(&kexp_0->u.KExpCCode.t0, &kloc_0, &v_1025),
         _fx_catch_225);
      FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_1025, &v_1026), _fx_catch_225);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1026, *top_inline_ccode_0, true, &v_1027), _fx_catch_225);
      _fx_free_LN15C_form__cstmt_t(top_inline_ccode_0);
      FX_COPY_PTR(v_1027, top_inline_ccode_0);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1);

   _fx_catch_225: ;
      if (v_1027) {
         _fx_free_LN15C_form__cstmt_t(&v_1027);
      }
      if (v_1026) {
         _fx_free_N15C_form__cstmt_t(&v_1026);
      }
      if (v_1025) {
         _fx_free_N14C_form__cexp_t(&v_1025);
      }
      fx_free_exn(&v_1024);
      if (v_1023) {
         _fx_free_rR23C_gen_code__block_ctx_t(&v_1023);
      }
      goto _fx_endmatch_49;
   }
   if (tag_0 == 31) {
      _fx_R17K_form__kdefval_t v_1029 = {0};
      _fx_R16Ast__val_flags_t kv_flags_1 = {0};
      fx_str_t kv_cname_0 = {0};
      _fx_N14K_form__ktyp_t kv_typ_1 = 0;
      _fx_N14C_form__ctyp_t ctyp_4 = 0;
      _fx_rR23C_gen_code__block_ctx_t bctx_1 = 0;
      _fx_T3SSR10Ast__loc_t v_1030 = {0};
      fx_str_t ccode_data_kind_0 = {0};
      fx_str_t ccode_data_lit_0 = {0};
      _fx_LN15C_form__cstmt_t ccode_179 = 0;
      _fx_N14C_form__cexp_t v_1031 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_1032 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1033 = {0};
      _fx_LN15C_form__cstmt_t delta_ccode_0 = 0;
      _fx_LN15C_form__cstmt_t v_1034 = 0;
      _fx_LN15C_form__cstmt_t v_1035 = 0;
      _fx_N14C_form__cexp_t tag_exp_0 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1036 = {0};
      _fx_LN14C_form__cexp_t v_1037 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1038 = {0};
      _fx_N14C_form__cexp_t init_exp_0 = 0;
      _fx_N14C_form__cexp_t v_1039 = 0;
      _fx_R16Ast__val_flags_t v_1040 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1041 = {0};
      _fx_N14C_form__cexp_t i_exp_15 = 0;
      _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti v_1042 = {0};
      _fx_N14C_form__ctyp_t struct_ctyp_0 = 0;
      fx_str_t v_1043 = {0};
      fx_str_t v_1044 = {0};
      _fx_N14C_form__cexp_t rc_exp_0 = 0;
      _fx_LN14C_form__cexp_t v_1045 = 0;
      _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1046 = {0};
      _fx_N14C_form__cexp_t data_init_0 = 0;
      _fx_R16Ast__val_flags_t v_1047 = {0};
      _fx_R16Ast__val_flags_t v_1048 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_1049 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1050 = {0};
      _fx_N14C_form__cexp_t data_exp_1 = 0;
      _fx_LN15C_form__cstmt_t delta_ccode_1 = 0;
      _fx_N14C_form__cexp_t v_1051 = 0;
      _fx_N14C_form__cexp_t init_exp_1 = 0;
      _fx_LN15C_form__cstmt_t delta_ccode_2 = 0;
      _fx_R16Ast__val_flags_t v_1052 = {0};
      _fx_R16Ast__val_flags_t v_1053 = {0};
      _fx_Nt6option1N14C_form__cexp_t v_1054 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1055 = {0};
      _fx_LN15C_form__cstmt_t delta_ccode_3 = 0;
      _fx_LN15C_form__cstmt_t v_1056 = 0;
      _fx_LN15C_form__cstmt_t v_1057 = 0;
      _fx_rNt6option1N14C_form__cexp_t v_1058 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1059 = {0};
      _fx_N14C_form__cexp_t ce2_5 = 0;
      _fx_LN15C_form__cstmt_t ccode_180 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t res_25 = {0};
      _fx_rNt6option1N14C_form__cexp_t v_1060 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1061 = {0};
      _fx_N14C_form__cexp_t ce2_6 = 0;
      _fx_LN15C_form__cstmt_t ccode_181 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1062 = {0};
      _fx_LN15C_form__cstmt_t saved_cleanup_0 = 0;
      _fx_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB v_1063 = {0};
      _fx_T2Nt6option1N14C_form__cexp_tB v_1064 = {0};
      _fx_Nt6option1N14C_form__cexp_t e0_opt_0 = {0};
      _fx_R16Ast__val_flags_t flags_2 = {0};
      _fx_Nt6option1N14C_form__cexp_t e0_opt_1 = {0};
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1065 = {0};
      _fx_N14C_form__cexp_t i_exp_16 = 0;
      _fx_LN15C_form__cstmt_t delta_ccode_4 = 0;
      _fx_LN15C_form__cstmt_t ccode_182 = 0;
      _fx_LN15C_form__cstmt_t v_1066 = 0;
      _fx_LN15C_form__cstmt_t v_1067 = 0;
      _fx_LN15C_form__cstmt_t v_1068 = 0;
      _fx_LN15C_form__cstmt_t v_1069 = 0;
      _fx_LN15C_form__cstmt_t v_1070 = 0;
      _fx_LN15C_form__cstmt_t v_1071 = 0;
      _fx_Nt6option1N14C_form__cexp_t v_1072 = {0};
      _fx_rNt6option1N14C_form__cexp_t v_1073 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1074 = {0};
      _fx_LN15C_form__cstmt_t ccode_183 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1075 = {0};
      _fx_N14C_form__cexp_t ce2_7 = 0;
      _fx_LN15C_form__cstmt_t ccode_184 = 0;
      _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1076 = {0};
      _fx_N15C_form__cinfo_t v_1077 = {0};
      _fx_T3R9Ast__id_tN14K_form__kexp_tR10Ast__loc_t* vcase_29 = &kexp_0->u.KDefVal;
      _fx_N14K_form__kexp_t e2_1 = vcase_29->t1;
      _fx_R9Ast__id_t* i_11 = &vcase_29->t0;
      FX_CALL(_fx_M6K_formFM8get_kvalRM9kdefval_t2R9Ast__id_tR10Ast__loc_t(i_11, &kloc_0, &v_1029, 0), _fx_catch_236);
      _fx_copy_R16Ast__val_flags_t(&v_1029.kv_flags, &kv_flags_1);
      fx_copy_str(&v_1029.kv_cname, &kv_cname_0);
      FX_COPY_PTR(v_1029.kv_typ, &kv_typ_1);
      bool res_26;
      FX_CALL(_fx_M6K_formFM13is_val_globalB1R16Ast__val_flags_t(&kv_flags_1, &res_26, 0), _fx_catch_236);
      bool t_15;
      if (res_26) {
         t_15 = true;
      }
      else {
         t_15 = kv_flags_1.val_flag_ctor > 0;
      }
      if (t_15) {
         FX_CALL(_fx_M10C_gen_codeFM3addv2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(*defined_syms_0, i_11, 0), _fx_catch_236);
      }
      _fx_R17K_form__ktprops_t v_1078;
      FX_CALL(
         _fx_M10K_annotateFM11get_ktpropsR17K_form__ktprops_t2N14K_form__ktyp_tR10Ast__loc_t(kv_typ_1, &kloc_0, &v_1078, 0),
         _fx_catch_236);
      bool ktp_scalar_0 = v_1078.ktp_scalar;
      bool ktp_complex_1 = v_1078.ktp_complex;
      bool ktp_ptr_2 = v_1078.ktp_ptr;
      FX_CALL(_fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(kv_typ_1, &kloc_0, &ctyp_4, 0),
         _fx_catch_236);
      FX_CALL(
         _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0,
            &bctx_1, 0), _fx_catch_236);
      if (FX_REC_VARIANT_TAG(e2_1) == 30) {
         _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t* vcase_30 = &e2_1->u.KExpCCode;
         fx_str_t slit_223 = FX_MAKE_STR("ccode");
         _fx_make_T3SSR10Ast__loc_t(&slit_223, &vcase_30->t0, &vcase_30->t1.t1, &v_1030);
      }
      else {
         fx_str_t slit_224 = FX_MAKE_STR("");
         fx_str_t slit_225 = FX_MAKE_STR("");
         _fx_make_T3SSR10Ast__loc_t(&slit_224, &slit_225, &kloc_0, &v_1030);
      }
      FX_CHECK_EXN(_fx_catch_236);
      fx_copy_str(&v_1030.t0, &ccode_data_kind_0);
      fx_copy_str(&v_1030.t1, &ccode_data_lit_0);
      _fx_R10Ast__loc_t ccode_loc_0 = v_1030.t2;
      int_ ctor_id_0 = kv_flags_1.val_flag_ctor;
      bool is_temp_0 = kv_flags_1.val_flag_temp;
      bool is_temp_ref_0 = kv_flags_1.val_flag_tempref;
      _fx_N24C_gen_code__block_kind_t v_1079 = bctx_1->data.bctx_kind;
      bool is_global_0;
      bool t_16;
      if (v_1079.tag == 1) {
         t_16 = !is_temp_0;
      }
      else {
         t_16 = false;
      }
      if (t_16) {
         is_global_0 = !is_temp_ref_0;
      }
      else {
         is_global_0 = false;
      }
      bool is_fast_cons_0;
      if (is_temp_0) {
         if (FX_REC_VARIANT_TAG(e2_1) == 6) {
            _fx_T4N13Ast__binary_tN14K_form__atom_tN14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_31 =
               &e2_1->u.KExpBinary;
            if (FX_REC_VARIANT_TAG(vcase_31->t0) == 26) {
               _fx_N14K_form__atom_t* v_1080 = &vcase_31->t2;
               if (v_1080->tag == 1) {
                  _fx_R9Ast__id_t* l_0 = &v_1080->u.AtomId;
                  bool res_27;
                  FX_CALL(_fx_M10C_gen_codeFM3memB2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(u1vals_0, l_0, &res_27, 0),
                     _fx_catch_236);
                  if (res_27) {
                     _fx_N15K_form__kinfo_t v_1081 = {0};
                     FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(l_0, &kloc_0, &v_1081, 0),
                        _fx_catch_226);
                     if (v_1081.tag == 2) {
                        is_fast_cons_0 = v_1081.u.KVal.kv_flags.val_flag_temp;
                     }
                     else {
                        is_fast_cons_0 = false;
                     }
                     FX_CHECK_EXN(_fx_catch_226);

                  _fx_catch_226: ;
                     _fx_free_N15K_form__kinfo_t(&v_1081);
                     goto _fx_endmatch_38;
                  }
               }
            }
         }
         is_fast_cons_0 = false;

      _fx_endmatch_38: ;
         FX_CHECK_EXN(_fx_catch_236);
      }
      else {
         is_fast_cons_0 = false;
      }
      bool v_1082;
      fx_str_t slit_226 = FX_MAKE_STR("ccode");
      v_1082 = _fx_F6__eq__B2SS(&ccode_data_kind_0, &slit_226, 0);
      if (v_1082) {
         FX_CALL(_fx_M6C_formFM9CExpCCodeN14C_form__cexp_t2SR10Ast__loc_t(&ccode_data_lit_0, &ccode_loc_0, &v_1031),
            _fx_catch_236);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1031, &v_1032);
         fx_str_t slit_227 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               i_11, ctyp_4, &kv_flags_1, &slit_227, &v_1032, 0, &kloc_0, &v_1033, 0), _fx_catch_236);
         FX_COPY_PTR(v_1033.t1, &delta_ccode_0);
         FX_COPY_PTR(bctx_1->data.bctx_prologue, &v_1034);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(delta_ccode_0, v_1034,
               &v_1035, 0), _fx_catch_236);
         _fx_LN15C_form__cstmt_t* v_1083 = &bctx_1->data.bctx_prologue;
         _fx_free_LN15C_form__cstmt_t(v_1083);
         FX_COPY_PTR(v_1035, v_1083);
         FX_COPY_PTR(ccode_0, &ccode_179);
      }
      else if (ctor_id_0 > 0) {
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(ctor_id_0, &kloc_0, &tag_exp_0, 0),
            _fx_catch_236);
         bool is_null_0;
         if (FX_REC_VARIANT_TAG(kv_typ_1) == 16) {
            _fx_N15K_form__kinfo_t v_1084 = {0};
            FX_CALL(
               _fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(&kv_typ_1->u.KTypName, &kloc_0, &v_1084, 0),
               _fx_catch_227);
            if (v_1084.tag == 5) {
               _fx_R21K_form__kdefvariant_t v_1085 = {0};
               _fx_copy_R21K_form__kdefvariant_t(&v_1084.u.KVariant->data, &v_1085);
               _fx_R16Ast__var_flags_t* kvar_flags_1 = &v_1085.kvar_flags;
               if (kvar_flags_1->var_flag_recursive) {
                  is_null_0 = kvar_flags_1->var_flag_opt;
               }
               else {
                  is_null_0 = false;
               }
               _fx_free_R21K_form__kdefvariant_t(&v_1085);
            }
            else {
               is_null_0 = false;
            }
            FX_CHECK_EXN(_fx_catch_227);

         _fx_catch_227: ;
            _fx_free_N15K_form__kinfo_t(&v_1084);
         }
         else {
            is_null_0 = false;
         }
         FX_CHECK_EXN(_fx_catch_236);
         if (!ktp_ptr_2) {
            FX_CALL(_fx_cons_LN14C_form__cexp_t(tag_exp_0, 0, true, &v_1037), _fx_catch_236);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_4, &kloc_0, &v_1038);
            FX_CALL(
               _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(v_1037, &v_1038,
                  &init_exp_0), _fx_catch_236);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(init_exp_0, 0, &v_1036);
         }
         else if (is_null_0) {
            FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&kloc_0, &v_1039, 0), _fx_catch_236);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_1039, 0, &v_1036);
         }
         else {
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_1040, 0), _fx_catch_236);
            fx_str_t slit_228 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  i_11, ctyp_4, &v_1040, &slit_228, &_fx_g18C_gen_code__None2_, 0, &kloc_0, &v_1041, 0), _fx_catch_236);
            FX_COPY_PTR(v_1041.t0, &i_exp_15);
            FX_CALL(
               _fx_M10C_gen_codeFM10get_structT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti1N14C_form__cexp_t(
                  i_exp_15, &v_1042, 0), _fx_catch_236);
            _fx_R9Ast__id_t rn_0 = v_1042.t0;
            FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&rn_0, &struct_ctyp_0), _fx_catch_236);
            FX_CALL(_fx_M3AstFM2ppS1RM4id_t(i_11, &v_1043, 0), _fx_catch_236);
            fx_str_t slit_229 = FX_MAKE_STR("_data");
            {
               const fx_str_t strs_35[] = { v_1043, slit_229 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_35, 2, &v_1044), _fx_catch_236);
            }
            _fx_R9Ast__id_t data_id_1;
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &v_1044, &data_id_1, 0), _fx_catch_236);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(1, &kloc_0, &rc_exp_0, 0), _fx_catch_236);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(tag_exp_0, 0, true, &v_1045), _fx_catch_236);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(rc_exp_0, v_1045, false, &v_1045), _fx_catch_236);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(struct_ctyp_0, &kloc_0, &v_1046);
            FX_CALL(
               _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(v_1045, &v_1046,
                  &data_init_0), _fx_catch_236);
            FX_CALL(_fx_M3AstFM17default_val_flagsRM11val_flags_t0(&v_1047, 0), _fx_catch_236);
            _fx_make_R16Ast__val_flags_t(v_1047.val_flag_arg, v_1047.val_flag_mutable, v_1047.val_flag_temp,
               v_1047.val_flag_tempref, true, v_1047.val_flag_subarray, v_1047.val_flag_instance, &v_1047.val_flag_method,
               v_1047.val_flag_ctor, v_1047.val_flag_global, &v_1048);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(data_init_0, &v_1049);
            fx_str_t slit_230 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &data_id_1, struct_ctyp_0, &v_1048, &slit_230, &v_1049, 0, &kloc_0, &v_1050, 0), _fx_catch_236);
            FX_COPY_PTR(v_1050.t0, &data_exp_1);
            FX_COPY_PTR(v_1050.t1, &delta_ccode_1);
            FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(data_exp_1, &v_1051, 0), _fx_catch_236);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_1051, delta_ccode_1, &v_1036);
         }
         FX_COPY_PTR(v_1036.t0, &init_exp_1);
         FX_COPY_PTR(v_1036.t1, &delta_ccode_2);
         FX_CALL(_fx_M3AstFM17default_val_flagsRM11val_flags_t0(&v_1052, 0), _fx_catch_236);
         _fx_make_R16Ast__val_flags_t(v_1052.val_flag_arg, v_1052.val_flag_mutable, v_1052.val_flag_temp,
            v_1052.val_flag_tempref, v_1052.val_flag_private, v_1052.val_flag_subarray, v_1052.val_flag_instance,
            &v_1052.val_flag_method, v_1052.val_flag_ctor, mod_sc_0, &v_1053);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(init_exp_1, &v_1054);
         fx_str_t slit_231 = FX_MAKE_STR("");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               i_11, ctyp_4, &v_1053, &slit_231, &v_1054, delta_ccode_2, &kloc_0, &v_1055, 0), _fx_catch_236);
         FX_COPY_PTR(v_1055.t1, &delta_ccode_3);
         FX_COPY_PTR(bctx_1->data.bctx_prologue, &v_1056);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(delta_ccode_3, v_1056,
               &v_1057, 0), _fx_catch_236);
         _fx_LN15C_form__cstmt_t* v_1086 = &bctx_1->data.bctx_prologue;
         _fx_free_LN15C_form__cstmt_t(v_1086);
         FX_COPY_PTR(v_1057, v_1086);
         FX_COPY_PTR(ccode_0, &ccode_179);
      }
      else {
         bool v_1087;
         if (is_fast_cons_0) {
            v_1087 = true;
         }
         else {
            bool t_17;
            if (is_temp_ref_0) {
               t_17 = true;
            }
            else if (ktp_scalar_0) {
               t_17 = is_temp_0;
            }
            else {
               t_17 = false;
            }
            if (t_17) {
               FX_CALL(_fx_M10C_gen_codeFM3memB2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(u1vals_0, i_11, &v_1087, 0),
                  _fx_catch_236);
            }
            else {
               v_1087 = false;
            }
         }
         if (v_1087) {
            FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1058), _fx_catch_236);
            FX_CALL(
               _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
                  e2_1, v_1058, ccode_0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
                  fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
                  return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1059, fx_fv), _fx_catch_236);
            FX_COPY_PTR(v_1059.t0, &ce2_5);
            FX_COPY_PTR(v_1059.t1, &ccode_180);
            fx_str_t slit_232 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  i_11, ctyp_4, &kv_flags_1, &slit_232, &_fx_g18C_gen_code__None2_, 0, &kloc_0, &res_25, 0), _fx_catch_236);
            FX_CALL(
               _fx_M10C_gen_codeFM3addv3Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_tN14C_form__cexp_t(*i2e_0, i_11,
                  ce2_5, 0), _fx_catch_236);
            FX_COPY_PTR(ccode_180, &ccode_179);
         }
         else if (is_temp_ref_0) {
            FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1060), _fx_catch_236);
            FX_CALL(
               _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
                  e2_1, v_1060, ccode_0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
                  fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
                  return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1061, fx_fv), _fx_catch_236);
            FX_COPY_PTR(v_1061.t0, &ce2_6);
            FX_COPY_PTR(v_1061.t1, &ccode_181);
            FX_CALL(
               _fx_M10C_gen_codeFM17add_local_temprefT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
                  i_11, ctyp_4, &kv_flags_1, ce2_6, ccode_181, &kloc_0, i2e_ref_0, &v_1062, 0), _fx_catch_236);
            FX_COPY_PTR(v_1062.t1, &ccode_179);
         }
         else {
            bool t_18;
            if (ktp_complex_1) {
               t_18 = true;
            }
            else {
               t_18 = is_global_0;
            }
            bool t_19;
            if (t_18) {
               t_19 = true;
            }
            else {
               int tag_30 = FX_REC_VARIANT_TAG(e2_1);
               bool res_28;
               if (tag_30 == 5) {
                  res_28 = true;
               }
               else if (tag_30 == 6) {
                  res_28 = true;
               }
               else if (tag_30 == 7) {
                  res_28 = true;
               }
               else if (tag_30 == 8) {
                  res_28 = true;
               }
               else if (tag_30 == 14) {
                  res_28 = true;
               }
               else if (tag_30 == 15) {
                  res_28 = true;
               }
               else if (tag_30 == 19) {
                  res_28 = true;
               }
               else if (tag_30 == 20) {
                  res_28 = true;
               }
               else if (tag_30 == 25) {
                  res_28 = true;
               }
               else if (tag_30 == 30) {
                  res_28 = true;
               }
               else {
                  res_28 = false;
               }
               FX_CHECK_EXN(_fx_catch_236);
               if (res_28) {
                  t_19 = false; goto _fx_endmatch_39;
               }
               t_19 = true;

            _fx_endmatch_39: ;
               FX_CHECK_EXN(_fx_catch_236);
            }
            if (t_19) {
               FX_COPY_PTR(bctx_1->data.bctx_cleanup, &saved_cleanup_0);
               _fx_LN15C_form__cstmt_t* v_1088 = &bctx_1->data.bctx_cleanup;
               _fx_free_LN15C_form__cstmt_t(v_1088);
               *v_1088 = 0;
               bool assign_e2_0;
               if (ktp_complex_1 == true) {
                  if (FX_REC_VARIANT_TAG(e2_1) == 5) {
                     _fx_N14K_form__atom_t* v_1089 = &e2_1->u.KExpAtom.t0;
                     if (v_1089->tag == 2) {
                        if (v_1089->u.AtomLit.tag == 8) {
                           assign_e2_0 = false; goto _fx_endmatch_40;
                        }
                     }
                  }
               }
               assign_e2_0 = true;

            _fx_endmatch_40: ;
               FX_CHECK_EXN(_fx_catch_236);
               if (!is_global_0) {
                  _fx_make_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB(&kv_flags_1, &_fx_g18C_gen_code__None2_,
                     assign_e2_0, &v_1063);
               }
               else {
                  if (ktp_complex_1) {
                     _fx_make_T2Nt6option1N14C_form__cexp_tB(&_fx_g18C_gen_code__None2_, assign_e2_0, &v_1064);
                  }
                  else {
                     bool t_20;
                     if (ktp_ptr_2) {
                        t_20 = true;
                     }
                     else {
                        t_20 = ktp_scalar_0;
                     }
                     if (t_20) {
                        if (FX_REC_VARIANT_TAG(e2_1) == 5) {
                           _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_32 = &e2_1->u.KExpAtom;
                           _fx_N14K_form__atom_t* v_1090 = &vcase_32->t0;
                           if (v_1090->tag == 2) {
                              _fx_N14C_form__ctyp_t e2_ctyp_0 = 0;
                              _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1091 = {0};
                              _fx_N14C_form__cexp_t v_1092 = 0;
                              _fx_Nt6option1N14C_form__cexp_t v_1093 = {0};
                              _fx_T2N14K_form__ktyp_tR10Ast__loc_t* v_1094 = &vcase_32->t1;
                              _fx_R10Ast__loc_t* e2_loc_0 = &v_1094->t1;
                              FX_CALL(
                                 _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(v_1094->t0,
                                    e2_loc_0, &e2_ctyp_0, 0), _fx_catch_228);
                              _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(e2_ctyp_0, e2_loc_0, &v_1091);
                              FX_CALL(
                                 _fx_M6C_formFM7CExpLitN14C_form__cexp_t2N14K_form__klit_tT2N14C_form__ctyp_tR10Ast__loc_t(
                                    &v_1090->u.AtomLit, &v_1091, &v_1092), _fx_catch_228);
                              _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1092, &v_1093);
                              _fx_make_T2Nt6option1N14C_form__cexp_tB(&v_1093, false, &v_1064);

                           _fx_catch_228: ;
                              _fx_free_Nt6option1N14C_form__cexp_t(&v_1093);
                              if (v_1092) {
                                 _fx_free_N14C_form__cexp_t(&v_1092);
                              }
                              _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1091);
                              if (e2_ctyp_0) {
                                 _fx_free_N14C_form__ctyp_t(&e2_ctyp_0);
                              }
                              goto _fx_endmatch_41;
                           }
                        }
                        _fx_make_T2Nt6option1N14C_form__cexp_tB(&_fx_g18C_gen_code__None2_, assign_e2_0, &v_1064);

                     _fx_endmatch_41: ;
                        FX_CHECK_EXN(_fx_catch_236);
                     }
                     else {
                        _fx_make_T2Nt6option1N14C_form__cexp_tB(&_fx_g18C_gen_code__None2_, assign_e2_0, &v_1064);
                     }
                  }
                  _fx_copy_Nt6option1N14C_form__cexp_t(&v_1064.t0, &e0_opt_0);
                  bool assign_e2_1 = v_1064.t1;
                  _fx_make_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB(&kv_flags_1, &e0_opt_0, assign_e2_1, &v_1063);
               }
               _fx_copy_R16Ast__val_flags_t(&v_1063.t0, &flags_2);
               _fx_copy_Nt6option1N14C_form__cexp_t(&v_1063.t1, &e0_opt_1);
               bool assign_e2_2 = v_1063.t2;
               FX_CALL(
                  _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     i_11, ctyp_4, &flags_2, &e0_opt_1, 0, &kloc_0, block_stack_ref_0, &v_1065, 0), _fx_catch_236);
               FX_COPY_PTR(v_1065.t0, &i_exp_16);
               FX_COPY_PTR(v_1065.t1, &delta_ccode_4);
               if (is_global_0) {
                  FX_COPY_PTR(bctx_1->data.bctx_prologue, &v_1066);
                  FX_CALL(
                     _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(delta_ccode_4,
                        v_1066, &v_1067, 0), _fx_catch_236);
                  _fx_LN15C_form__cstmt_t* v_1095 = &bctx_1->data.bctx_prologue;
                  _fx_free_LN15C_form__cstmt_t(v_1095);
                  FX_COPY_PTR(v_1067, v_1095);
                  FX_COPY_PTR(ccode_0, &ccode_182);
               }
               else {
                  FX_CALL(
                     _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(delta_ccode_4,
                        ccode_0, &ccode_182, 0), _fx_catch_236);
               }
               if (is_global_0) {
                  FX_COPY_PTR(bctx_1->data.bctx_cleanup, &v_1068);
                  FX_CALL(
                     _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_1068,
                        *module_cleanup_0, &v_1069, 0), _fx_catch_236);
                  _fx_free_LN15C_form__cstmt_t(module_cleanup_0);
                  FX_COPY_PTR(v_1069, module_cleanup_0);
                  _fx_LN15C_form__cstmt_t* v_1096 = &bctx_1->data.bctx_cleanup;
                  _fx_free_LN15C_form__cstmt_t(v_1096);
                  FX_COPY_PTR(saved_cleanup_0, v_1096);
               }
               else {
                  FX_COPY_PTR(bctx_1->data.bctx_cleanup, &v_1070);
                  FX_CALL(
                     _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_1070,
                        saved_cleanup_0, &v_1071, 0), _fx_catch_236);
                  _fx_LN15C_form__cstmt_t* v_1097 = &bctx_1->data.bctx_cleanup;
                  _fx_free_LN15C_form__cstmt_t(v_1097);
                  FX_COPY_PTR(v_1071, v_1097);
               }
               if (assign_e2_2) {
                  _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(i_exp_16, &v_1072);
                  FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&v_1072, &v_1073), _fx_catch_236);
                  FX_CALL(
                     _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
                        e2_1, v_1073, ccode_182, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
                        fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0,
                        module_cleanup_ref_0, return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1074, fx_fv),
                     _fx_catch_236);
                  FX_COPY_PTR(v_1074.t1, &ccode_183);
                  if (ccode_183 != 0) {
                     _fx_LN15C_form__cstmt_t v_1098 = ccode_183->tl;
                     if (v_1098 != 0) {
                        _fx_N15C_form__cstmt_t v_1099 = v_1098->hd;
                        if (FX_REC_VARIANT_TAG(v_1099) == 16) {
                           _fx_T4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t* vcase_33 =
                              &v_1099->u.CDefVal;
                           if (vcase_33->t2.tag == 1) {
                              _fx_N15C_form__cstmt_t v_1100 = ccode_183->hd;
                              if (FX_REC_VARIANT_TAG(v_1100) == 3) {
                                 _fx_N14C_form__cexp_t v_1101 = v_1100->u.CExp;
                                 if (FX_REC_VARIANT_TAG(v_1101) == 3) {
                                    _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t*
                                       vcase_34 = &v_1101->u.CExpBinary;
                                    if (vcase_34->t0.tag == 15) {
                                       _fx_N14C_form__cexp_t v_1102 = vcase_34->t1;
                                       if (FX_REC_VARIANT_TAG(v_1102) == 1) {
                                          _fx_R9Ast__id_t* i_12 = &vcase_33->t1;
                                          bool res_29;
                                          FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&v_1102->u.CExpIdent.t0, i_12, &res_29, 0),
                                             _fx_catch_236);
                                          if (res_29) {
                                             _fx_Nt6option1N14C_form__cexp_t v_1103 = {0};
                                             _fx_N15C_form__cstmt_t v_1104 = 0;
                                             _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(vcase_34->t2,
                                                &v_1103);
                                             FX_CALL(
                                                _fx_M6C_formFM7CDefValN15C_form__cstmt_t4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(
                                                   vcase_33->t0, i_12, &v_1103, &vcase_34->t3.t1, &v_1104), _fx_catch_229);
                                             FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1104, v_1098->tl, true, &ccode_179),
                                                _fx_catch_229);

                                          _fx_catch_229: ;
                                             if (v_1104) {
                                                _fx_free_N15C_form__cstmt_t(&v_1104);
                                             }
                                             _fx_free_Nt6option1N14C_form__cexp_t(&v_1103);
                                             goto _fx_endmatch_42;
                                          }
                                       }
                                    }
                                 }
                              }
                           }
                        }
                     }
                  }
                  FX_COPY_PTR(ccode_183, &ccode_179);

               _fx_endmatch_42: ;
                  FX_CHECK_EXN(_fx_catch_236);
               }
               else {
                  FX_COPY_PTR(ccode_182, &ccode_179);
               }
            }
            else {
               if (ktp_ptr_2 == false) {
                  if (FX_REC_VARIANT_TAG(e2_1) == 5) {
                     _fx_T2N14K_form__atom_tT2N14K_form__ktyp_tR10Ast__loc_t* vcase_35 = &e2_1->u.KExpAtom;
                     _fx_N14K_form__atom_t* v_1105 = &vcase_35->t0;
                     if (v_1105->tag == 2) {
                        if (v_1105->u.AtomLit.tag == 8) {
                           _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_1106 = {0};
                           _fx_N14C_form__cexp_t v_1107 = 0;
                           _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(ctyp_4, &vcase_35->t1.t1, &v_1106);
                           FX_CALL(
                              _fx_M6C_formFM8CExpInitN14C_form__cexp_t2LN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(0,
                                 &v_1106, &v_1107), _fx_catch_230);
                           _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(v_1107, ccode_0, &v_1075);

                        _fx_catch_230: ;
                           if (v_1107) {
                              _fx_free_N14C_form__cexp_t(&v_1107);
                           }
                           _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1106);
                           goto _fx_endmatch_43;
                        }
                     }
                  }
               }
               _fx_rNt6option1N14C_form__cexp_t v_1108 = 0;
               FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1108), _fx_catch_231);
               FX_CALL(
                  _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
                     e2_1, v_1108, ccode_0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
                     fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
                     return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1075, fx_fv), _fx_catch_231);

            _fx_catch_231: ;
               if (v_1108) {
                  _fx_free_rNt6option1N14C_form__cexp_t(&v_1108);
               }

            _fx_endmatch_43: ;
               FX_CHECK_EXN(_fx_catch_236);
               FX_COPY_PTR(v_1075.t0, &ce2_7);
               FX_COPY_PTR(v_1075.t1, &ccode_184);
               if (FX_REC_VARIANT_TAG(e2_1) == 15) {
                  if (ccode_184 != 0) {
                     _fx_N15C_form__cstmt_t v_1109 = ccode_184->hd;
                     if (FX_REC_VARIANT_TAG(v_1109) == 16) {
                        _fx_Nt6option1N14C_form__cexp_t* v_1110 = &v_1109->u.CDefVal.t2;
                        if (v_1110->tag == 2) {
                           _fx_Nt6option1N14C_form__cexp_t v_1111 = {0};
                           _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1110->u.Some, &v_1111);
                           FX_CALL(
                              _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                                 i_11, ctyp_4, &kv_flags_1, &v_1111, ccode_184->tl, &kloc_0, block_stack_ref_0, &v_1076, 0),
                              _fx_catch_232);

                        _fx_catch_232: ;
                           _fx_free_Nt6option1N14C_form__cexp_t(&v_1111);
                           goto _fx_endmatch_44;
                        }
                     }
                  }
               }
               if (FX_REC_VARIANT_TAG(e2_1) == 14) {
                  if (ccode_184 != 0) {
                     _fx_N15C_form__cstmt_t v_1112 = ccode_184->hd;
                     if (FX_REC_VARIANT_TAG(v_1112) == 16) {
                        _fx_Nt6option1N14C_form__cexp_t* v_1113 = &v_1112->u.CDefVal.t2;
                        if (v_1113->tag == 2) {
                           _fx_Nt6option1N14C_form__cexp_t v_1114 = {0};
                           _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1113->u.Some, &v_1114);
                           FX_CALL(
                              _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                                 i_11, ctyp_4, &kv_flags_1, &v_1114, ccode_184->tl, &kloc_0, block_stack_ref_0, &v_1076, 0),
                              _fx_catch_233);

                        _fx_catch_233: ;
                           _fx_free_Nt6option1N14C_form__cexp_t(&v_1114);
                           goto _fx_endmatch_44;
                        }
                     }
                  }
               }
               _fx_Nt6option1N14C_form__cexp_t v_1115 = {0};
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(ce2_7, &v_1115);
               FX_CALL(
                  _fx_M10C_gen_codeFM9add_localT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                     i_11, ctyp_4, &kv_flags_1, &v_1115, ccode_184, &kloc_0, block_stack_ref_0, &v_1076, 0), _fx_catch_234);

            _fx_catch_234: ;
               _fx_free_Nt6option1N14C_form__cexp_t(&v_1115);

            _fx_endmatch_44: ;
               FX_CHECK_EXN(_fx_catch_236);
               FX_COPY_PTR(v_1076.t1, &ccode_179);
            }
         }
      }
      if (FX_STR_LENGTH(kv_cname_0) != 0) {
         FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(i_11, &kloc_0, &v_1077, 0), _fx_catch_236);
         if (v_1077.tag == 2) {
            _fx_R17C_form__cdefval_t cv_3 = {0};
            _fx_N15C_form__cinfo_t v_1116 = {0};
            _fx_R17C_form__cdefval_t* cv_4 = &v_1077.u.CVal;
            _fx_make_R17C_form__cdefval_t(&cv_4->cv_name, cv_4->cv_typ, &kv_cname_0, &cv_4->cv_flags, &cv_4->cv_loc, &cv_3);
            _fx_M6C_formFM4CValN15C_form__cinfo_t1RM9cdefval_t(&cv_3, &v_1116);
            FX_CALL(_fx_M6C_formFM13set_idc_entryv2R9Ast__id_tN15C_form__cinfo_t(i_11, &v_1116, 0), _fx_catch_235);

         _fx_catch_235: ;
            _fx_free_N15C_form__cinfo_t(&v_1116);
            _fx_free_R17C_form__cdefval_t(&cv_3);
         }
         FX_CHECK_EXN(_fx_catch_236);
      }
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_179, &v_1);

   _fx_catch_236: ;
      _fx_free_N15C_form__cinfo_t(&v_1077);
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1076);
      if (ccode_184) {
         _fx_free_LN15C_form__cstmt_t(&ccode_184);
      }
      if (ce2_7) {
         _fx_free_N14C_form__cexp_t(&ce2_7);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1075);
      if (ccode_183) {
         _fx_free_LN15C_form__cstmt_t(&ccode_183);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1074);
      if (v_1073) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1073);
      }
      _fx_free_Nt6option1N14C_form__cexp_t(&v_1072);
      if (v_1071) {
         _fx_free_LN15C_form__cstmt_t(&v_1071);
      }
      if (v_1070) {
         _fx_free_LN15C_form__cstmt_t(&v_1070);
      }
      if (v_1069) {
         _fx_free_LN15C_form__cstmt_t(&v_1069);
      }
      if (v_1068) {
         _fx_free_LN15C_form__cstmt_t(&v_1068);
      }
      if (v_1067) {
         _fx_free_LN15C_form__cstmt_t(&v_1067);
      }
      if (v_1066) {
         _fx_free_LN15C_form__cstmt_t(&v_1066);
      }
      if (ccode_182) {
         _fx_free_LN15C_form__cstmt_t(&ccode_182);
      }
      if (delta_ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&delta_ccode_4);
      }
      if (i_exp_16) {
         _fx_free_N14C_form__cexp_t(&i_exp_16);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1065);
      _fx_free_Nt6option1N14C_form__cexp_t(&e0_opt_1);
      _fx_free_R16Ast__val_flags_t(&flags_2);
      _fx_free_Nt6option1N14C_form__cexp_t(&e0_opt_0);
      _fx_free_T2Nt6option1N14C_form__cexp_tB(&v_1064);
      _fx_free_T3R16Ast__val_flags_tNt6option1N14C_form__cexp_tB(&v_1063);
      if (saved_cleanup_0) {
         _fx_free_LN15C_form__cstmt_t(&saved_cleanup_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1062);
      if (ccode_181) {
         _fx_free_LN15C_form__cstmt_t(&ccode_181);
      }
      if (ce2_6) {
         _fx_free_N14C_form__cexp_t(&ce2_6);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1061);
      if (v_1060) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1060);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&res_25);
      if (ccode_180) {
         _fx_free_LN15C_form__cstmt_t(&ccode_180);
      }
      if (ce2_5) {
         _fx_free_N14C_form__cexp_t(&ce2_5);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1059);
      if (v_1058) {
         _fx_free_rNt6option1N14C_form__cexp_t(&v_1058);
      }
      if (v_1057) {
         _fx_free_LN15C_form__cstmt_t(&v_1057);
      }
      if (v_1056) {
         _fx_free_LN15C_form__cstmt_t(&v_1056);
      }
      if (delta_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&delta_ccode_3);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1055);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_1054);
      _fx_free_R16Ast__val_flags_t(&v_1053);
      _fx_free_R16Ast__val_flags_t(&v_1052);
      if (delta_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&delta_ccode_2);
      }
      if (init_exp_1) {
         _fx_free_N14C_form__cexp_t(&init_exp_1);
      }
      if (v_1051) {
         _fx_free_N14C_form__cexp_t(&v_1051);
      }
      if (delta_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&delta_ccode_1);
      }
      if (data_exp_1) {
         _fx_free_N14C_form__cexp_t(&data_exp_1);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1050);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_1049);
      _fx_free_R16Ast__val_flags_t(&v_1048);
      _fx_free_R16Ast__val_flags_t(&v_1047);
      if (data_init_0) {
         _fx_free_N14C_form__cexp_t(&data_init_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1046);
      if (v_1045) {
         _fx_free_LN14C_form__cexp_t(&v_1045);
      }
      if (rc_exp_0) {
         _fx_free_N14C_form__cexp_t(&rc_exp_0);
      }
      FX_FREE_STR(&v_1044);
      FX_FREE_STR(&v_1043);
      if (struct_ctyp_0) {
         _fx_free_N14C_form__ctyp_t(&struct_ctyp_0);
      }
      _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&v_1042);
      if (i_exp_15) {
         _fx_free_N14C_form__cexp_t(&i_exp_15);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1041);
      _fx_free_R16Ast__val_flags_t(&v_1040);
      if (v_1039) {
         _fx_free_N14C_form__cexp_t(&v_1039);
      }
      if (init_exp_0) {
         _fx_free_N14C_form__cexp_t(&init_exp_0);
      }
      _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_1038);
      if (v_1037) {
         _fx_free_LN14C_form__cexp_t(&v_1037);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1036);
      if (tag_exp_0) {
         _fx_free_N14C_form__cexp_t(&tag_exp_0);
      }
      if (v_1035) {
         _fx_free_LN15C_form__cstmt_t(&v_1035);
      }
      if (v_1034) {
         _fx_free_LN15C_form__cstmt_t(&v_1034);
      }
      if (delta_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&delta_ccode_0);
      }
      _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1033);
      _fx_free_Nt6option1N14C_form__cexp_t(&v_1032);
      if (v_1031) {
         _fx_free_N14C_form__cexp_t(&v_1031);
      }
      if (ccode_179) {
         _fx_free_LN15C_form__cstmt_t(&ccode_179);
      }
      FX_FREE_STR(&ccode_data_lit_0);
      FX_FREE_STR(&ccode_data_kind_0);
      _fx_free_T3SSR10Ast__loc_t(&v_1030);
      if (bctx_1) {
         _fx_free_rR23C_gen_code__block_ctx_t(&bctx_1);
      }
      if (ctyp_4) {
         _fx_free_N14C_form__ctyp_t(&ctyp_4);
      }
      if (kv_typ_1) {
         _fx_free_N14K_form__ktyp_t(&kv_typ_1);
      }
      FX_FREE_STR(&kv_cname_0);
      _fx_free_R16Ast__val_flags_t(&kv_flags_1);
      _fx_free_R17K_form__kdefval_t(&v_1029);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 32) {
      fx_str_t kf_cname_0 = {0};
      _fx_N14K_form__kexp_t kf_body_0 = 0;
      _fx_N14K_form__ktyp_t kf_rt_0 = 0;
      _fx_N15C_form__cinfo_t v_1117 = {0};
      _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t v_1118 = {0};
      _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t args_17 = 0;
      _fx_N14C_form__ctyp_t rt_0 = 0;
      _fx_rR17C_form__cdeffun_t cf_0 = 0;
      _fx_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB v_1119 = {0};
      _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t real_args_0 = 0;
      _fx_rB really_nothrow_0 = 0;
      _fx_LN15C_form__cstmt_t new_body_0 = 0;
      _fx_LN15C_form__cstmt_t v_1120 = 0;
      _fx_R17C_form__cdeffun_t v_1121 = {0};
      _fx_R17K_form__kdeffun_t* v_1122 = &kexp_0->u.KDefFun->data;
      _fx_R10Ast__loc_t kf_loc_0 = v_1122->kf_loc;
      _fx_R16Ast__fun_flags_t kf_flags_0 = v_1122->kf_flags;
      fx_copy_str(&v_1122->kf_cname, &kf_cname_0);
      FX_COPY_PTR(v_1122->kf_body, &kf_body_0);
      _fx_R25K_form__kdefclosureinfo_t kf_closure_0 = v_1122->kf_closure;
      FX_COPY_PTR(v_1122->kf_rt, &kf_rt_0);
      _fx_R9Ast__id_t kf_name_0 = v_1122->kf_name;
      _fx_R9Ast__id_t kci_fcv_t_0 = kf_closure_0.kci_fcv_t;
      _fx_R9Ast__id_t kci_arg_0 = kf_closure_0.kci_arg;
      _fx_N17Ast__fun_constr_t ctor_0 = kf_flags_0.fun_flag_ctor;
      bool res_30;
      FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&kci_arg_0, &_fx_g9Ast__noid, &res_30, 0), _fx_catch_256);
      if (res_30) {
         FX_CALL(
            _fx_M10C_gen_codeFM33ensure_sym_is_defined_or_declaredv4R9Ast__id_tR10Ast__loc_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_t(
               &kf_name_0, &kf_loc_0, defined_syms_ref_0, fwd_fdecls_ref_0, 0), _fx_catch_256);
      }
      FX_CALL(_fx_M10C_gen_codeFM3addv2Nt10Hashset__t1R9Ast__id_tR9Ast__id_t(*defined_syms_0, &kf_name_0, 0), _fx_catch_256);
      _fx_N24C_gen_code__block_kind_t v_1123;
      _fx_M10C_gen_codeFM13BlockKind_FunN24C_gen_code__block_kind_t1R9Ast__id_t(&kf_name_0, &v_1123);
      FX_CALL(
         _fx_M10C_gen_codeFM13new_block_ctxv4N24C_gen_code__block_kind_tR10Ast__loc_trLrRM11block_ctx_ti(&v_1123, &kloc_0,
            block_stack_ref_0, km_idx_0, 0), _fx_catch_256);
      FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(&kf_name_0, &kf_loc_0, &v_1117, 0),
         _fx_catch_256);
      if (v_1117.tag == 3) {
         _fx_R17C_form__cdeffun_t v_1124 = {0};
         _fx_rR17C_form__cdeffun_t cf_1 = v_1117.u.CFun;
         _fx_copy_R17C_form__cdeffun_t(&cf_1->data, &v_1124);
         bool is_nothrow_2 = v_1124.cf_flags.fun_flag_nothrow;
         _fx_make_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t(
            v_1124.cf_args, v_1124.cf_rt, is_nothrow_2, cf_1, &v_1118);
         _fx_free_R17C_form__cdeffun_t(&v_1124);
      }
      else {
         fx_str_t v_1125 = {0};
         fx_str_t v_1126 = {0};
         fx_str_t v_1127 = {0};
         fx_exn_t v_1128 = {0};
         FX_CALL(_fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(&kf_name_0, &kf_loc_0, &v_1125, 0), _fx_catch_237);
         FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1125, &v_1126, 0), _fx_catch_237);
         fx_str_t slit_233 = FX_MAKE_STR("cgen: the function \'");
         fx_str_t slit_234 = FX_MAKE_STR("\' declaration was not properly converted");
         {
            const fx_str_t strs_36[] = { slit_233, v_1126, slit_234 };
            FX_CALL(fx_strjoin(0, 0, 0, strs_36, 3, &v_1127), _fx_catch_237);
         }
         FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kf_loc_0, &v_1127, &v_1128, 0), _fx_catch_237);
         FX_THROW(&v_1128, false, _fx_catch_237);

      _fx_catch_237: ;
         fx_free_exn(&v_1128);
         FX_FREE_STR(&v_1127);
         FX_FREE_STR(&v_1126);
         FX_FREE_STR(&v_1125);
      }
      FX_CHECK_EXN(_fx_catch_256);
      FX_COPY_PTR(v_1118.t0, &args_17);
      FX_COPY_PTR(v_1118.t1, &rt_0);
      bool is_nothrow_3 = v_1118.t2;
      FX_COPY_PTR(v_1118.t3, &cf_0);
      FX_CALL(
         _fx_M10C_gen_codeFM15unpack_fun_argsT4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB3LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tB(
            args_17, rt_0, is_nothrow_3, &v_1119, 0), _fx_catch_256);
      FX_COPY_PTR(v_1119.t0, &real_args_0);
      _fx_R9Ast__id_t retid_0 = v_1119.t1;
      FX_CALL(_fx_make_rB(false, &really_nothrow_0), _fx_catch_256);
      int_ nreal_args_0;
      FX_CALL(
         _fx_M10C_gen_codeFM8length1_i1LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(real_args_0, &nreal_args_0, 0),
         _fx_catch_256);
      if (ctor_0.tag == 1) {
         if (FX_REC_VARIANT_TAG(kf_body_0) == 30) {
            _fx_N14C_form__cexp_t v_1129 = 0;
            _fx_N15C_form__cstmt_t v_1130 = 0;
            _fx_T2ST2N14K_form__ktyp_tR10Ast__loc_t* vcase_36 = &kf_body_0->u.KExpCCode;
            FX_CALL(_fx_M6C_formFM9CExpCCodeN14C_form__cexp_t2SR10Ast__loc_t(&vcase_36->t0, &vcase_36->t1.t1, &v_1129),
               _fx_catch_238);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_1129, &v_1130), _fx_catch_238);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1130, 0, true, &new_body_0), _fx_catch_238);

         _fx_catch_238: ;
            if (v_1130) {
               _fx_free_N15C_form__cstmt_t(&v_1130);
            }
            if (v_1129) {
               _fx_free_N14C_form__cexp_t(&v_1129);
            }
            goto _fx_endmatch_48;
         }
      }
      if (ctor_0.tag == 1) {
         _fx_Nt6option1N14C_form__cexp_t v_1131 = {0};
         _fx_N14C_form__cexp_t v_1132 = 0;
         _fx_N14C_form__cexp_t v_1133 = 0;
         _fx_rNt6option1N14C_form__cexp_t dstexp_r_1 = 0;
         _fx_R16Ast__val_flags_t v_1134 = {0};
         _fx_N14C_form__cexp_t v_1135 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1136 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1137 = {0};
         _fx_N14C_form__cexp_t status_exp_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_185 = 0;
         _fx_LN15C_form__cstmt_t ccode_186 = 0;
         _fx_N14C_form__cexp_t call_chkstk_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_187 = 0;
         _fx_N14C_form__ctyp_t v_1138 = 0;
         _fx_N14C_form__ctyp_t fcv_ptr_ctyp_0 = 0;
         _fx_N14C_form__cexp_t fcv_arg_exp0_0 = 0;
         _fx_N14C_form__cexp_t cast_ptr_0 = 0;
         _fx_R16Ast__val_flags_t v_1139 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_1140 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1141 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1142 = {0};
         _fx_N14C_form__cexp_t ret_e_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_188 = 0;
         _fx_rR23C_gen_code__block_ctx_t bctx_2 = 0;
         _fx_LN15C_form__cstmt_t ccode_189 = 0;
         _fx_LN15C_form__cstmt_t bctx_cleanup_2 = 0;
         _fx_LN15C_form__cstmt_t bctx_prologue_2 = 0;
         _fx_LN15C_form__cstmt_t ccode_190 = 0;
         _fx_N15C_form__cstmt_t v_1143 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1144 = {0};
         _fx_Nt6option1N14C_form__cexp_t v_1145 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1146 = {0};
         _fx_N14C_form__cexp_t ret_e_1 = 0;
         _fx_LN15C_form__cstmt_t ccode_191 = 0;
         _fx_LN15C_form__cstmt_t v_1147 = 0;
         _fx_N14C_form__cexp_t ret_e_2 = 0;
         _fx_LN15C_form__cstmt_t ccode_192 = 0;
         _fx_LN15C_form__cstmt_t ccode_193 = 0;
         _fx_N14C_form__cexp_t chk_ret_0 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1148 = {0};
         _fx_N15C_form__cstmt_t v_1149 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1150 = {0};
         _fx_N15C_form__cstmt_t v_1151 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1152 = {0};
         _fx_N15C_form__cstmt_t v_1153 = 0;
         _fx_LN15C_form__cstmt_t v_1154 = 0;
         _fx_LN15C_form__cstmt_t v_1155 = 0;
         bool res_31;
         FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&retid_0, &_fx_g9Ast__noid, &res_31, 0), _fx_catch_241);
         if (res_31) {
            _fx_copy_Nt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1131);
         }
         else {
            FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&retid_0, &kf_loc_0, &v_1132, 0),
               _fx_catch_241);
            FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(v_1132, &v_1133, 0), _fx_catch_241);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1133, &v_1131);
         }
         FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&v_1131, &dstexp_r_1), _fx_catch_241);
         _fx_free_rNt6option1N14C_form__cexp_t(func_dstexp_r_0);
         FX_COPY_PTR(dstexp_r_1, func_dstexp_r_0);
         *return_used_0 = 0;
         _fx_R9Ast__id_t orig_status_id_0;
         fx_str_t slit_235 = FX_MAKE_STR("fx_status");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_235, &orig_status_id_0, 0), _fx_catch_241);
         FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_1134, 0), _fx_catch_241);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kf_loc_0, &v_1135, 0), _fx_catch_241);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1135, &v_1136);
         fx_str_t slit_236 = FX_MAKE_STR("fx_status");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &orig_status_id_0, _fx_g20C_gen_code__CTypCInt, &v_1134, &slit_236, &v_1136, 0, &kf_loc_0, &v_1137, 0),
            _fx_catch_241);
         FX_COPY_PTR(v_1137.t0, &status_exp_0);
         FX_COPY_PTR(v_1137.t1, &ccode_185);
         _fx_R9Ast__id_t status_id_0;
         if (is_nothrow_3) {
            status_id_0 = _fx_g9Ast__noid;
         }
         else {
            status_id_0 = orig_status_id_0;
         }
         bool res_32;
         FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&status_id_0, &_fx_g9Ast__noid, &res_32, 0), _fx_catch_241);
         bool t_21;
         if (res_32) {
            t_21 = true;
         }
         else {
            t_21 = !kf_flags_0.fun_flag_recursive;
         }
         if (t_21) {
            FX_COPY_PTR(ccode_185, &ccode_186);
         }
         else {
            _fx_R9Ast__id_t v_1156;
            fx_str_t slit_237 = FX_MAKE_STR("fx_check_stack");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_237, &v_1156, 0), _fx_catch_241);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_1156, 0,
                  _fx_g20C_gen_code__CTypCInt, &kf_loc_0, &call_chkstk_0, 0), _fx_catch_241);
            FX_CALL(
               _fx_M10C_gen_codeFM11add_fx_callLN15C_form__cstmt_t4N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                  call_chkstk_0, ccode_185, &kf_loc_0, block_stack_ref_0, &ccode_186, 0), _fx_catch_241);
         }
         _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t lst_29 = real_args_0;
         for (; lst_29; lst_29 = lst_29->tl) {
            _fx_LN19C_form__carg_attr_t flags_3 = 0;
            _fx_N14C_form__cexp_t v_1157 = 0;
            _fx_N14C_form__cexp_t v_1158 = 0;
            _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* __pat___11 = &lst_29->hd;
            _fx_R9Ast__id_t a_12 = __pat___11->t0;
            FX_COPY_PTR(__pat___11->t2, &flags_3);
            bool v_1159;
            FX_CALL(
               _fx_M10C_gen_codeFM3memB2LN19C_form__carg_attr_tN19C_form__carg_attr_t(flags_3,
                  &_fx_g25C_gen_code__CArgPassByPtr, &v_1159, 0), _fx_catch_239);
            if (v_1159) {
               FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&a_12, &kf_loc_0, &v_1157, 0),
                  _fx_catch_239);
               FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(v_1157, &v_1158, 0), _fx_catch_239);
               FX_CALL(
                  _fx_M10C_gen_codeFM3addv3Nt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tR9Ast__id_tN14C_form__cexp_t(*i2e_0,
                     &a_12, v_1158, 0), _fx_catch_239);
            }

         _fx_catch_239: ;
            if (v_1158) {
               _fx_free_N14C_form__cexp_t(&v_1158);
            }
            if (v_1157) {
               _fx_free_N14C_form__cexp_t(&v_1157);
            }
            FX_FREE_LIST_SIMPLE(&flags_3);
            FX_CHECK_EXN(_fx_catch_241);
         }
         bool res_33;
         FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&kci_arg_0, &_fx_g9Ast__noid, &res_33, 0), _fx_catch_241);
         if (res_33) {
            FX_COPY_PTR(ccode_186, &ccode_187);
         }
         else {
            FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&kci_fcv_t_0, &v_1138), _fx_catch_241);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(v_1138, &fcv_ptr_ctyp_0, 0), _fx_catch_241);
            _fx_R9Ast__id_t v_1160;
            fx_str_t slit_238 = FX_MAKE_STR("fx_fv");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_238, &v_1160, 0), _fx_catch_241);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&v_1160,
                  _fx_g23C_form__std_CTypVoidPtr, &kf_loc_0, &fcv_arg_exp0_0, 0), _fx_catch_241);
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(fcv_arg_exp0_0,
                  fcv_ptr_ctyp_0, &kf_loc_0, &cast_ptr_0), _fx_catch_241);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_1139, 0), _fx_catch_241);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(cast_ptr_0, &v_1140);
            fx_str_t slit_239 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &kci_arg_0, fcv_ptr_ctyp_0, &v_1139, &slit_239, &v_1140, ccode_186, &kf_loc_0, &v_1141, 0), _fx_catch_241);
            FX_COPY_PTR(v_1141.t1, &ccode_187);
         }
         FX_CALL(
            _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
               kf_body_0, dstexp_r_1, ccode_187, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
               fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
               return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1142, fx_fv), _fx_catch_241);
         FX_COPY_PTR(v_1142.t0, &ret_e_0);
         FX_COPY_PTR(v_1142.t1, &ccode_188);
         _fx_R10Ast__loc_t end_loc_0;
         FX_CALL(_fx_M6K_formFM12get_kexp_endR10Ast__loc_t1N14K_form__kexp_t(kf_body_0, &end_loc_0, 0), _fx_catch_241);
         FX_CALL(
            _fx_M10C_gen_codeFM14curr_block_ctxrRM11block_ctx_t2R10Ast__loc_trLrRM11block_ctx_t(&end_loc_0, block_stack_ref_0,
               &bctx_2, 0), _fx_catch_241);
         if (ccode_188 != 0) {
            _fx_N15C_form__cstmt_t v_1161 = ccode_188->hd;
            if (FX_REC_VARIANT_TAG(v_1161) == 3) {
               _fx_N14C_form__cexp_t v_1162 = v_1161->u.CExp;
               if (FX_REC_VARIANT_TAG(v_1162) == 9) {
                  _fx_N14C_form__cexp_t v_1163 = v_1162->u.CExpCall.t0;
                  if (FX_REC_VARIANT_TAG(v_1163) == 1) {
                     bool res_34;
                     FX_CALL(
                        _fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&v_1163->u.CExpIdent.t0, &_fx_g24C_form__std_FX_CHECK_EXN, &res_34,
                           0), _fx_catch_241);
                     if (res_34) {
                        bctx_2->data.bctx_label_used = bctx_2->data.bctx_label_used - 1;
                        FX_COPY_PTR(ccode_188->tl, &ccode_189);
                        goto _fx_endmatch_45;
                     }
                  }
               }
            }
         }
         FX_COPY_PTR(ccode_188, &ccode_189);

      _fx_endmatch_45: ;
         FX_CHECK_EXN(_fx_catch_241);
         _fx_R23C_gen_code__block_ctx_t* v_1164 = &bctx_2->data;
         int_ bctx_label_used_2 = v_1164->bctx_label_used;
         FX_COPY_PTR(v_1164->bctx_cleanup, &bctx_cleanup_2);
         FX_COPY_PTR(v_1164->bctx_prologue, &bctx_prologue_2);
         _fx_R9Ast__id_t bctx_label_2 = v_1164->bctx_label;
         bool t_22;
         if (bctx_label_used_2 > 0) {
            t_22 = true;
         }
         else {
            t_22 = *return_used_0 > 0;
         }
         if (t_22) {
            FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&bctx_label_2, &end_loc_0, &v_1143),
               _fx_catch_241);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1143, ccode_189, true, &ccode_190), _fx_catch_241);
         }
         else {
            FX_COPY_PTR(ccode_189, &ccode_190);
         }
         if (bctx_cleanup_2 == 0) {
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(ret_e_0, ccode_190, &v_1144);
         }
         else {
            bool res_35;
            FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&retid_0, &_fx_g9Ast__noid, &res_35, 0), _fx_catch_241);
            bool t_23;
            if (res_35) {
               t_23 = true;
            }
            else {
               FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&status_id_0, &_fx_g9Ast__noid, &t_23, 0),
                  _fx_catch_241);
            }
            bool t_24;
            if (t_23) {
               t_24 = true;
            }
            else {
               _fx_copy_Nt6option1N14C_form__cexp_t(&dstexp_r_1->data, &v_1145);
               FX_CALL(_fx_M10C_gen_codeFM6issomeB1Nt6option1N14C_form__cexp_t(&v_1145, &t_24, 0), _fx_catch_241);
            }
            if (t_24) {
               _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(ret_e_0, ccode_190, &v_1146);
            }
            else {
               int tag_31 = FX_REC_VARIANT_TAG(ret_e_0);
               bool res_36;
               if (tag_31 == 10) {
                  if (ret_e_0->u.CExpInit.t0 == 0) {
                     res_36 = true; goto _fx_endmatch_46;
                  }
               }
               if (tag_31 == 2) {
                  res_36 = true; goto _fx_endmatch_46;
               }
               if (tag_31 == 1) {
                  res_36 = true; goto _fx_endmatch_46;
               }
               res_36 = false;

            _fx_endmatch_46: ;
               FX_CHECK_EXN(_fx_catch_241);
               if (res_36) {
                  _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(ret_e_0, ccode_190, &v_1146); goto _fx_endmatch_47;
               }
               _fx_N14C_form__ctyp_t v_1165 = 0;
               _fx_R16Ast__val_flags_t v_1166 = {0};
               _fx_Nt6option1N14C_form__cexp_t v_1167 = {0};
               _fx_R9Ast__id_t v_1168;
               fx_str_t slit_240 = FX_MAKE_STR("result");
               FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_240, &v_1168, 0), _fx_catch_240);
               FX_CALL(_fx_M6C_formFM12get_cexp_typN14C_form__ctyp_t1N14C_form__cexp_t(ret_e_0, &v_1165, 0), _fx_catch_240);
               FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_1166, 0), _fx_catch_240);
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(ret_e_0, &v_1167);
               fx_str_t slit_241 = FX_MAKE_STR("");
               FX_CALL(
                  _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                     &v_1168, v_1165, &v_1166, &slit_241, &v_1167, ccode_190, &end_loc_0, &v_1146, 0), _fx_catch_240);

            _fx_catch_240: ;
               _fx_free_Nt6option1N14C_form__cexp_t(&v_1167);
               _fx_free_R16Ast__val_flags_t(&v_1166);
               if (v_1165) {
                  _fx_free_N14C_form__ctyp_t(&v_1165);
               }

            _fx_endmatch_47: ;
               FX_CHECK_EXN(_fx_catch_241);
            }
            FX_COPY_PTR(v_1146.t0, &ret_e_1);
            FX_COPY_PTR(v_1146.t1, &ccode_191);
            FX_CALL(
               _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(bctx_cleanup_2, ccode_191,
                  &v_1147, 0), _fx_catch_241);
            _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(ret_e_1, v_1147, &v_1144);
         }
         FX_COPY_PTR(v_1144.t0, &ret_e_2);
         FX_COPY_PTR(v_1144.t1, &ccode_192);
         bool res_37;
         FX_CALL(_fx_M10C_gen_codeFM6__ne__B2R9Ast__id_tR9Ast__id_t(&status_id_0, &_fx_g9Ast__noid, &res_37, 0), _fx_catch_241);
         if (res_37) {
            if (*return_used_0 > 0) {
               _fx_R9Ast__id_t v_1169;
               fx_str_t slit_242 = FX_MAKE_STR("FX_CHECK_RETURN");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_242, &v_1169, 0), _fx_catch_241);
               FX_CALL(
                  _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(&v_1169,
                     0, _fx_g20C_gen_code__CTypCInt, &end_loc_0, &chk_ret_0, 0), _fx_catch_241);
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(chk_ret_0, &v_1148);
               FX_CALL(
                  _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_1148, &end_loc_0,
                     &v_1149), _fx_catch_241);
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1149, ccode_192, true, &ccode_193), _fx_catch_241);
            }
            else {
               _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(status_exp_0, &v_1150);
               FX_CALL(
                  _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_1150, &end_loc_0,
                     &v_1151), _fx_catch_241);
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1151, ccode_192, true, &ccode_193), _fx_catch_241);
            }
         }
         else if (FX_REC_VARIANT_TAG(rt_0) == 8) {
            FX_COPY_PTR(ccode_192, &ccode_193);
         }
         else {
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(ret_e_2, &v_1152);
            FX_CALL(
               _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_1152, &end_loc_0,
                  &v_1153), _fx_catch_241);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1153, ccode_192, true, &ccode_193), _fx_catch_241);
         }
         FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(bctx_prologue_2, &v_1154, 0), _fx_catch_241);
         FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(ccode_193, &v_1155, 0), _fx_catch_241);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_1154, v_1155, &new_body_0,
               0), _fx_catch_241);

      _fx_catch_241: ;
         if (v_1155) {
            _fx_free_LN15C_form__cstmt_t(&v_1155);
         }
         if (v_1154) {
            _fx_free_LN15C_form__cstmt_t(&v_1154);
         }
         if (v_1153) {
            _fx_free_N15C_form__cstmt_t(&v_1153);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1152);
         if (v_1151) {
            _fx_free_N15C_form__cstmt_t(&v_1151);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1150);
         if (v_1149) {
            _fx_free_N15C_form__cstmt_t(&v_1149);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1148);
         if (chk_ret_0) {
            _fx_free_N14C_form__cexp_t(&chk_ret_0);
         }
         if (ccode_193) {
            _fx_free_LN15C_form__cstmt_t(&ccode_193);
         }
         if (ccode_192) {
            _fx_free_LN15C_form__cstmt_t(&ccode_192);
         }
         if (ret_e_2) {
            _fx_free_N14C_form__cexp_t(&ret_e_2);
         }
         if (v_1147) {
            _fx_free_LN15C_form__cstmt_t(&v_1147);
         }
         if (ccode_191) {
            _fx_free_LN15C_form__cstmt_t(&ccode_191);
         }
         if (ret_e_1) {
            _fx_free_N14C_form__cexp_t(&ret_e_1);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1146);
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1145);
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1144);
         if (v_1143) {
            _fx_free_N15C_form__cstmt_t(&v_1143);
         }
         if (ccode_190) {
            _fx_free_LN15C_form__cstmt_t(&ccode_190);
         }
         if (bctx_prologue_2) {
            _fx_free_LN15C_form__cstmt_t(&bctx_prologue_2);
         }
         if (bctx_cleanup_2) {
            _fx_free_LN15C_form__cstmt_t(&bctx_cleanup_2);
         }
         if (ccode_189) {
            _fx_free_LN15C_form__cstmt_t(&ccode_189);
         }
         if (bctx_2) {
            _fx_free_rR23C_gen_code__block_ctx_t(&bctx_2);
         }
         if (ccode_188) {
            _fx_free_LN15C_form__cstmt_t(&ccode_188);
         }
         if (ret_e_0) {
            _fx_free_N14C_form__cexp_t(&ret_e_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1142);
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1141);
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1140);
         _fx_free_R16Ast__val_flags_t(&v_1139);
         if (cast_ptr_0) {
            _fx_free_N14C_form__cexp_t(&cast_ptr_0);
         }
         if (fcv_arg_exp0_0) {
            _fx_free_N14C_form__cexp_t(&fcv_arg_exp0_0);
         }
         if (fcv_ptr_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&fcv_ptr_ctyp_0);
         }
         if (v_1138) {
            _fx_free_N14C_form__ctyp_t(&v_1138);
         }
         if (ccode_187) {
            _fx_free_LN15C_form__cstmt_t(&ccode_187);
         }
         if (call_chkstk_0) {
            _fx_free_N14C_form__cexp_t(&call_chkstk_0);
         }
         if (ccode_186) {
            _fx_free_LN15C_form__cstmt_t(&ccode_186);
         }
         if (ccode_185) {
            _fx_free_LN15C_form__cstmt_t(&ccode_185);
         }
         if (status_exp_0) {
            _fx_free_N14C_form__cexp_t(&status_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1137);
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1136);
         if (v_1135) {
            _fx_free_N14C_form__cexp_t(&v_1135);
         }
         _fx_free_R16Ast__val_flags_t(&v_1134);
         if (dstexp_r_1) {
            _fx_free_rNt6option1N14C_form__cexp_t(&dstexp_r_1);
         }
         if (v_1133) {
            _fx_free_N14C_form__cexp_t(&v_1133);
         }
         if (v_1132) {
            _fx_free_N14C_form__cexp_t(&v_1132);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1131);
         goto _fx_endmatch_48;
      }
      if (ctor_0.tag == 3) {
         _fx_N14C_form__cexp_t var_exp_0 = 0;
         _fx_N14C_form__ctyp_t result_ctyp_0 = 0;
         _fx_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t v_1170 = {0};
         _fx_N14C_form__cexp_t v_1171 = 0;
         _fx_LN14C_form__cexp_t v_1172 = 0;
         _fx_N14C_form__cexp_t alloc_var_0 = 0;
         _fx_R16Ast__val_flags_t v_1173 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1174 = {0};
         _fx_N14C_form__cexp_t var_exp_1 = 0;
         _fx_N15C_form__cstmt_t v_1175 = 0;
         _fx_LN15C_form__cstmt_t ccode_194 = 0;
         _fx_LN15C_form__cstmt_t ccode_195 = 0;
         _fx_N14C_form__ctyp_t ifaces_ctyp_0 = 0;
         _fx_N14C_form__ctyp_t ifaces_ptr_ctyp_0 = 0;
         _fx_N14C_form__cexp_t v_1176 = 0;
         _fx_N14C_form__cexp_t v_1177 = 0;
         _fx_N14C_form__cexp_t v_1178 = 0;
         _fx_N14C_form__cexp_t v_1179 = 0;
         _fx_N15C_form__cstmt_t v_1180 = 0;
         _fx_N14C_form__cexp_t v_1181 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1182 = {0};
         _fx_N15C_form__cstmt_t v_1183 = 0;
         _fx_LN15C_form__cstmt_t ret_ccode_0 = 0;
         _fx_N14C_form__cexp_t var_exp_2 = 0;
         _fx_LN15C_form__cstmt_t ccode_196 = 0;
         _fx_LN15C_form__cstmt_t ret_ccode_1 = 0;
         _fx_N14C_form__cexp_t v_1184 = 0;
         _fx_N14C_form__cexp_t v_1185 = 0;
         _fx_N14C_form__cexp_t init_tag_0 = 0;
         _fx_LN15C_form__cstmt_t ccode_197 = 0;
         _fx_N15C_form__cstmt_t v_1186 = 0;
         _fx_N14C_form__cexp_t dst_base_0 = 0;
         _fx_N14C_form__cexp_t dst_base_1 = 0;
         _fx_LN15C_form__cstmt_t __fold_result___24 = 0;
         _fx_LN15C_form__cstmt_t ccode_198 = 0;
         _fx_LN15C_form__cstmt_t v_1187 = 0;
         _fx_T3BBR9Ast__id_t v_1188;
         if (FX_REC_VARIANT_TAG(kf_rt_0) == 16) {
            _fx_N15K_form__kinfo_t v_1189 = {0};
            _fx_R9Ast__id_t* vn_1 = &kf_rt_0->u.KTypName;
            FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(vn_1, &kf_loc_0, &v_1189, 0),
               _fx_catch_244);
            if (v_1189.tag == 5) {
               _fx_R21K_form__kdefvariant_t v_1190 = {0};
               _fx_N15C_form__cinfo_t v_1191 = {0};
               _fx_copy_R21K_form__kdefvariant_t(&v_1189.u.KVariant->data, &v_1190);
               _fx_R16Ast__var_flags_t* kvar_flags_2 = &v_1190.kvar_flags;
               bool have_tag_1 = kvar_flags_2->var_flag_have_tag;
               bool is_recursive_1 = kvar_flags_2->var_flag_recursive;
               FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(vn_1, &kf_loc_0, &v_1191, 0),
                  _fx_catch_242);
               _fx_R9Ast__id_t ifaces_id_0;
               if (v_1191.tag == 4) {
                  _fx_R17C_form__cdeftyp_t v_1192 = {0};
                  _fx_copy_R17C_form__cdeftyp_t(&v_1191.u.CTyp->data, &v_1192);
                  ifaces_id_0 = v_1192.ct_ifaces_id;
                  _fx_free_R17C_form__cdeftyp_t(&v_1192);
               }
               else {
                  ifaces_id_0 = _fx_g9Ast__noid;
               }
               FX_CHECK_EXN(_fx_catch_242);
               _fx_T3BBR9Ast__id_t tup_3 = { have_tag_1, is_recursive_1, ifaces_id_0 };
               v_1188 = tup_3;

            _fx_catch_242: ;
               _fx_free_N15C_form__cinfo_t(&v_1191);
               _fx_free_R21K_form__kdefvariant_t(&v_1190);
            }
            else {
               fx_str_t v_1193 = {0};
               fx_str_t v_1194 = {0};
               fx_str_t v_1195 = {0};
               fx_exn_t v_1196 = {0};
               FX_CALL(_fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(&kf_name_0, &kf_loc_0, &v_1193, 0), _fx_catch_243);
               FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1193, &v_1194, 0), _fx_catch_243);
               fx_str_t slit_243 = FX_MAKE_STR("cgen: the return type of variant constructor ");
               fx_str_t slit_244 = FX_MAKE_STR(" is not variant");
               {
                  const fx_str_t strs_37[] = { slit_243, v_1194, slit_244 };
                  FX_CALL(fx_strjoin(0, 0, 0, strs_37, 3, &v_1195), _fx_catch_243);
               }
               FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kf_loc_0, &v_1195, &v_1196, 0), _fx_catch_243);
               FX_THROW(&v_1196, false, _fx_catch_243);

            _fx_catch_243: ;
               fx_free_exn(&v_1196);
               FX_FREE_STR(&v_1195);
               FX_FREE_STR(&v_1194);
               FX_FREE_STR(&v_1193);
            }
            FX_CHECK_EXN(_fx_catch_244);

         _fx_catch_244: ;
            _fx_free_N15K_form__kinfo_t(&v_1189);
         }
         else {
            fx_str_t v_1197 = {0};
            fx_str_t v_1198 = {0};
            fx_str_t v_1199 = {0};
            fx_exn_t v_1200 = {0};
            FX_CALL(_fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(&kf_name_0, &kf_loc_0, &v_1197, 0), _fx_catch_245);
            FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1197, &v_1198, 0), _fx_catch_245);
            fx_str_t slit_245 = FX_MAKE_STR("cgen: the return type of variant constructor ");
            fx_str_t slit_246 = FX_MAKE_STR(" is not variant");
            {
               const fx_str_t strs_38[] = { slit_245, v_1198, slit_246 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_38, 3, &v_1199), _fx_catch_245);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kf_loc_0, &v_1199, &v_1200, 0), _fx_catch_245);
            FX_THROW(&v_1200, false, _fx_catch_245);

         _fx_catch_245: ;
            fx_free_exn(&v_1200);
            FX_FREE_STR(&v_1199);
            FX_FREE_STR(&v_1198);
            FX_FREE_STR(&v_1197);
         }
         FX_CHECK_EXN(_fx_catch_247);
         bool have_tag_2 = v_1188.t0;
         bool is_recursive_variant_0 = v_1188.t1;
         _fx_R9Ast__id_t ifaces_id_1 = v_1188.t2;
         FX_CALL(_fx_M6C_formFM11make_id_expN14C_form__cexp_t2R9Ast__id_tR10Ast__loc_t(&retid_0, &kf_loc_0, &var_exp_0, 0),
            _fx_catch_247);
         FX_CALL(
            _fx_M11C_gen_typesFM9ktyp2ctypN14C_form__ctyp_t2N14K_form__ktyp_tR10Ast__loc_t(kf_rt_0, &kf_loc_0, &result_ctyp_0,
               0), _fx_catch_247);
         if (is_recursive_variant_0) {
            FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(result_ctyp_0, &kf_loc_0, &v_1171),
               _fx_catch_247);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1171, 0, true, &v_1172), _fx_catch_247);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g48C_form__std_FX_MAKE_RECURSIVE_VARIANT_IMPL_START, v_1172, _fx_g20C_gen_code__CTypVoid, &kf_loc_0,
                  &alloc_var_0, 0), _fx_catch_247);
            _fx_R9Ast__id_t v_1201;
            fx_str_t slit_247 = FX_MAKE_STR("v");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_247, &v_1201, 0), _fx_catch_247);
            FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_1173, 0), _fx_catch_247);
            fx_str_t slit_248 = FX_MAKE_STR("v");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_1201, result_ctyp_0, &v_1173, &slit_248, &_fx_g18C_gen_code__None2_, 0, &kf_loc_0, &v_1174, 0),
               _fx_catch_247);
            FX_COPY_PTR(v_1174.t0, &var_exp_1);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(alloc_var_0, &v_1175), _fx_catch_247);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1175, 0, true, &ccode_194), _fx_catch_247);
            bool res_38;
            FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&ifaces_id_1, &_fx_g9Ast__noid, &res_38, 0), _fx_catch_247);
            if (res_38) {
               FX_COPY_PTR(ccode_194, &ccode_195);
            }
            else {
               _fx_R9Ast__id_t v_1202;
               fx_str_t slit_249 = FX_MAKE_STR("fx_ifaces_t");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_249, &v_1202, 0), _fx_catch_247);
               FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&v_1202, &ifaces_ctyp_0), _fx_catch_247);
               FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(ifaces_ctyp_0, &ifaces_ptr_ctyp_0, 0),
                  _fx_catch_247);
               _fx_R9Ast__id_t v_1203;
               fx_str_t slit_250 = FX_MAKE_STR("ifaces");
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_250, &v_1203, 0), _fx_catch_247);
               FX_CALL(
                  _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(var_exp_1, &v_1203,
                     ifaces_ptr_ctyp_0, &v_1176, 0), _fx_catch_247);
               FX_CALL(
                  _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&ifaces_id_1,
                     ifaces_ctyp_0, &kloc_0, &v_1177, 0), _fx_catch_247);
               FX_CALL(_fx_M6C_formFM13cexp_get_addrN14C_form__cexp_t1N14C_form__cexp_t(v_1177, &v_1178, 0), _fx_catch_247);
               FX_CALL(
                  _fx_M6C_formFM11make_assignN14C_form__cexp_t2N14C_form__cexp_tN14C_form__cexp_t(v_1176, v_1178, &v_1179, 0),
                  _fx_catch_247);
               FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(v_1179, &v_1180), _fx_catch_247);
               FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1180, ccode_194, true, &ccode_195), _fx_catch_247);
            }
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kf_loc_0, &v_1181, 0), _fx_catch_247);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1181, &v_1182);
            FX_CALL(
               _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_1182, &kf_loc_0,
                  &v_1183), _fx_catch_247);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1183, 0, true, &ret_ccode_0), _fx_catch_247);
            _fx_make_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(var_exp_1, ccode_195, ret_ccode_0, &v_1170);
         }
         else {
            _fx_make_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(var_exp_0, 0, 0, &v_1170);
         }
         FX_COPY_PTR(v_1170.t0, &var_exp_2);
         FX_COPY_PTR(v_1170.t1, &ccode_196);
         FX_COPY_PTR(v_1170.t2, &ret_ccode_1);
         _fx_R9Ast__id_t v_1204;
         fx_str_t slit_251 = FX_MAKE_STR("tag");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_251, &v_1204, 0), _fx_catch_247);
         FX_CALL(
            _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(var_exp_2, &v_1204,
               _fx_g19C_gen_code__CTypInt, &v_1184, 0), _fx_catch_247);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(ctor_0.u.CtorVariant, &kloc_0, &v_1185, 0),
            _fx_catch_247);
         FX_CALL(
            _fx_M6C_formFM11make_assignN14C_form__cexp_t2N14C_form__cexp_tN14C_form__cexp_t(v_1184, v_1185, &init_tag_0, 0),
            _fx_catch_247);
         if (have_tag_2) {
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(init_tag_0, &v_1186), _fx_catch_247);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1186, ccode_196, true, &ccode_197), _fx_catch_247);
         }
         else {
            FX_COPY_PTR(ccode_196, &ccode_197);
         }
         _fx_R9Ast__id_t v_1205;
         fx_str_t slit_252 = FX_MAKE_STR("u");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_252, &v_1205, 0), _fx_catch_247);
         FX_CALL(
            _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(var_exp_2, &v_1205,
               _fx_g19C_gen_code__CTypAny, &dst_base_0, 0), _fx_catch_247);
         _fx_R9Ast__id_t v_1206;
         FX_CALL(_fx_M3AstFM11get_orig_idRM4id_t1RM4id_t(&kf_name_0, &v_1206, 0), _fx_catch_247);
         FX_CALL(
            _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(dst_base_0, &v_1206,
               _fx_g19C_gen_code__CTypAny, &dst_base_1, 0), _fx_catch_247);
         FX_COPY_PTR(ccode_197, &__fold_result___24);
         int_ idx_2 = 0;
         _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t lst_30 = real_args_0;
         for (; lst_30; lst_30 = lst_30->tl, idx_2 += 1) {
            _fx_N14C_form__ctyp_t t_25 = 0;
            _fx_LN19C_form__carg_attr_t flags_4 = 0;
            _fx_LN15C_form__cstmt_t ccode_199 = 0;
            _fx_N14C_form__cexp_t src_exp_2 = 0;
            _fx_T2N14C_form__cexp_tN14C_form__ctyp_t v_1207 = {0};
            _fx_N14C_form__cexp_t src_exp_3 = 0;
            _fx_N14C_form__ctyp_t t_26 = 0;
            _fx_N14C_form__cexp_t dst_exp_19 = 0;
            fx_str_t v_1208 = {0};
            fx_str_t v_1209 = {0};
            _fx_LN15C_form__cstmt_t v_1210 = 0;
            _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* __pat___12 = &lst_30->hd;
            _fx_R9Ast__id_t a_13 = __pat___12->t0;
            FX_COPY_PTR(__pat___12->t1, &t_25);
            FX_COPY_PTR(__pat___12->t2, &flags_4);
            FX_COPY_PTR(__fold_result___24, &ccode_199);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&a_13, t_25, &kf_loc_0,
                  &src_exp_2, 0), _fx_catch_246);
            FX_CALL(
               _fx_M10C_gen_codeFM19maybe_deref_fun_argT2N14C_form__cexp_tN14C_form__ctyp_t5iN14C_form__cexp_tN14C_form__ctyp_tLN19C_form__carg_attr_tR10Ast__loc_t(
                  idx_2, src_exp_2, t_25, flags_4, &kf_loc_0, &v_1207, 0), _fx_catch_246);
            FX_COPY_PTR(v_1207.t0, &src_exp_3);
            FX_COPY_PTR(v_1207.t1, &t_26);
            if (nreal_args_0 == 1) {
               FX_COPY_PTR(dst_base_1, &dst_exp_19);
            }
            else {
               FX_CALL(_fx_F6stringS1i(idx_2, &v_1208, 0), _fx_catch_246);
               fx_str_t slit_253 = FX_MAKE_STR("t");
               {
                  const fx_str_t strs_39[] = { slit_253, v_1208 };
                  FX_CALL(fx_strjoin(0, 0, 0, strs_39, 2, &v_1209), _fx_catch_246);
               }
               _fx_R9Ast__id_t tup_elem_0;
               FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&v_1209, &tup_elem_0, 0), _fx_catch_246);
               FX_CALL(
                  _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(dst_base_1,
                     &tup_elem_0, t_26, &dst_exp_19, 0), _fx_catch_246);
            }
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  src_exp_3, dst_exp_19, t_26, ccode_199, &kf_loc_0, &v_1210, 0), _fx_catch_246);
            _fx_free_LN15C_form__cstmt_t(&__fold_result___24);
            FX_COPY_PTR(v_1210, &__fold_result___24);

         _fx_catch_246: ;
            if (v_1210) {
               _fx_free_LN15C_form__cstmt_t(&v_1210);
            }
            FX_FREE_STR(&v_1209);
            FX_FREE_STR(&v_1208);
            if (dst_exp_19) {
               _fx_free_N14C_form__cexp_t(&dst_exp_19);
            }
            if (t_26) {
               _fx_free_N14C_form__ctyp_t(&t_26);
            }
            if (src_exp_3) {
               _fx_free_N14C_form__cexp_t(&src_exp_3);
            }
            _fx_free_T2N14C_form__cexp_tN14C_form__ctyp_t(&v_1207);
            if (src_exp_2) {
               _fx_free_N14C_form__cexp_t(&src_exp_2);
            }
            if (ccode_199) {
               _fx_free_LN15C_form__cstmt_t(&ccode_199);
            }
            FX_FREE_LIST_SIMPLE(&flags_4);
            if (t_25) {
               _fx_free_N14C_form__ctyp_t(&t_25);
            }
            FX_CHECK_EXN(_fx_catch_247);
         }
         FX_COPY_PTR(__fold_result___24, &ccode_198);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(ret_ccode_1, ccode_198,
               &v_1187, 0), _fx_catch_247);
         FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(v_1187, &new_body_0, 0), _fx_catch_247);

      _fx_catch_247: ;
         if (v_1187) {
            _fx_free_LN15C_form__cstmt_t(&v_1187);
         }
         if (ccode_198) {
            _fx_free_LN15C_form__cstmt_t(&ccode_198);
         }
         if (__fold_result___24) {
            _fx_free_LN15C_form__cstmt_t(&__fold_result___24);
         }
         if (dst_base_1) {
            _fx_free_N14C_form__cexp_t(&dst_base_1);
         }
         if (dst_base_0) {
            _fx_free_N14C_form__cexp_t(&dst_base_0);
         }
         if (v_1186) {
            _fx_free_N15C_form__cstmt_t(&v_1186);
         }
         if (ccode_197) {
            _fx_free_LN15C_form__cstmt_t(&ccode_197);
         }
         if (init_tag_0) {
            _fx_free_N14C_form__cexp_t(&init_tag_0);
         }
         if (v_1185) {
            _fx_free_N14C_form__cexp_t(&v_1185);
         }
         if (v_1184) {
            _fx_free_N14C_form__cexp_t(&v_1184);
         }
         if (ret_ccode_1) {
            _fx_free_LN15C_form__cstmt_t(&ret_ccode_1);
         }
         if (ccode_196) {
            _fx_free_LN15C_form__cstmt_t(&ccode_196);
         }
         if (var_exp_2) {
            _fx_free_N14C_form__cexp_t(&var_exp_2);
         }
         if (ret_ccode_0) {
            _fx_free_LN15C_form__cstmt_t(&ret_ccode_0);
         }
         if (v_1183) {
            _fx_free_N15C_form__cstmt_t(&v_1183);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1182);
         if (v_1181) {
            _fx_free_N14C_form__cexp_t(&v_1181);
         }
         if (v_1180) {
            _fx_free_N15C_form__cstmt_t(&v_1180);
         }
         if (v_1179) {
            _fx_free_N14C_form__cexp_t(&v_1179);
         }
         if (v_1178) {
            _fx_free_N14C_form__cexp_t(&v_1178);
         }
         if (v_1177) {
            _fx_free_N14C_form__cexp_t(&v_1177);
         }
         if (v_1176) {
            _fx_free_N14C_form__cexp_t(&v_1176);
         }
         if (ifaces_ptr_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&ifaces_ptr_ctyp_0);
         }
         if (ifaces_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&ifaces_ctyp_0);
         }
         if (ccode_195) {
            _fx_free_LN15C_form__cstmt_t(&ccode_195);
         }
         if (ccode_194) {
            _fx_free_LN15C_form__cstmt_t(&ccode_194);
         }
         if (v_1175) {
            _fx_free_N15C_form__cstmt_t(&v_1175);
         }
         if (var_exp_1) {
            _fx_free_N14C_form__cexp_t(&var_exp_1);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1174);
         _fx_free_R16Ast__val_flags_t(&v_1173);
         if (alloc_var_0) {
            _fx_free_N14C_form__cexp_t(&alloc_var_0);
         }
         if (v_1172) {
            _fx_free_LN14C_form__cexp_t(&v_1172);
         }
         if (v_1171) {
            _fx_free_N14C_form__cexp_t(&v_1171);
         }
         _fx_free_T3N14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_1170);
         if (result_ctyp_0) {
            _fx_free_N14C_form__ctyp_t(&result_ctyp_0);
         }
         if (var_exp_0) {
            _fx_free_N14C_form__cexp_t(&var_exp_0);
         }
         goto _fx_endmatch_48;
      }
      if (ctor_0.tag == 4) {
         _fx_N15K_form__kinfo_t v_1211 = {0};
         _fx_N14C_form__ctyp_t fcv_t_0 = 0;
         _fx_T2BNt6option1N14C_form__cexp_t v_1212 = {0};
         _fx_N14C_form__cexp_t free_f_exp_4 = 0;
         _fx_N14C_form__cexp_t v_1213 = 0;
         _fx_N14C_form__cexp_t v_1214 = 0;
         _fx_LN14C_form__cexp_t v_1215 = 0;
         _fx_N14C_form__cexp_t alloc_fcv_0 = 0;
         _fx_N14C_form__ctyp_t v_1216 = 0;
         _fx_R16Ast__val_flags_t v_1217 = {0};
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1218 = {0};
         _fx_N14C_form__cexp_t fcv_exp_0 = 0;
         _fx_N14C_form__cexp_t v_1219 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1220 = {0};
         _fx_N15C_form__cstmt_t v_1221 = 0;
         _fx_LN15C_form__cstmt_t ret_ccode_2 = 0;
         _fx_N15C_form__cstmt_t v_1222 = 0;
         _fx_LN15C_form__cstmt_t ccode_200 = 0;
         _fx_LN15C_form__cstmt_t __fold_result___25 = 0;
         _fx_LN15C_form__cstmt_t ccode_201 = 0;
         _fx_LN15C_form__cstmt_t v_1223 = 0;
         _fx_R9Ast__id_t* f_id_0 = &ctor_0.u.CtorFP;
         FX_CALL(_fx_M6K_formFM6kinfo_N15K_form__kinfo_t2R9Ast__id_tR10Ast__loc_t(f_id_0, &kf_loc_0, &v_1211, 0),
            _fx_catch_251);
         _fx_R9Ast__id_t fcv_t_id_0;
         if (v_1211.tag == 3) {
            _fx_R17K_form__kdeffun_t v_1224 = {0};
            _fx_copy_R17K_form__kdeffun_t(&v_1211.u.KFun->data, &v_1224);
            fcv_t_id_0 = v_1224.kf_closure.kci_fcv_t;
            _fx_free_R17K_form__kdeffun_t(&v_1224);
         }
         else {
            fx_str_t v_1225 = {0};
            fx_str_t v_1226 = {0};
            fx_str_t v_1227 = {0};
            fx_exn_t v_1228 = {0};
            FX_CALL(_fx_M6K_formFM13get_idk_cnameS2R9Ast__id_tR10Ast__loc_t(f_id_0, &kf_loc_0, &v_1225, 0), _fx_catch_248);
            FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1225, &v_1226, 0), _fx_catch_248);
            fx_str_t slit_254 = FX_MAKE_STR("cgen: \'");
            fx_str_t slit_255 = FX_MAKE_STR("\' is not a function");
            {
               const fx_str_t strs_40[] = { slit_254, v_1226, slit_255 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_40, 3, &v_1227), _fx_catch_248);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kf_loc_0, &v_1227, &v_1228, 0), _fx_catch_248);
            FX_THROW(&v_1228, false, _fx_catch_248);

         _fx_catch_248: ;
            fx_free_exn(&v_1228);
            FX_FREE_STR(&v_1227);
            FX_FREE_STR(&v_1226);
            FX_FREE_STR(&v_1225);
         }
         FX_CHECK_EXN(_fx_catch_251);
         FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&fcv_t_id_0, &fcv_t_0), _fx_catch_251);
         FX_CALL(
            _fx_M11C_gen_typesFM10get_free_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(fcv_t_0, true,
               false, &kf_loc_0, &v_1212, 0), _fx_catch_251);
         _fx_Nt6option1N14C_form__cexp_t* v_1229 = &v_1212.t1;
         if (v_1229->tag == 2) {
            FX_COPY_PTR(v_1229->u.Some, &free_f_exp_4);
         }
         else {
            fx_str_t v_1230 = {0};
            fx_str_t v_1231 = {0};
            fx_str_t v_1232 = {0};
            fx_exn_t v_1233 = {0};
            FX_CALL(_fx_M6K_formFM13get_idk_cnameS2R9Ast__id_tR10Ast__loc_t(&fcv_t_id_0, &kf_loc_0, &v_1230, 0), _fx_catch_249);
            FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1230, &v_1231, 0), _fx_catch_249);
            fx_str_t slit_256 = FX_MAKE_STR("cgen: missing destructor for closure vars \'");
            fx_str_t slit_257 = FX_MAKE_STR("\'");
            {
               const fx_str_t strs_41[] = { slit_256, v_1231, slit_257 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_41, 3, &v_1232), _fx_catch_249);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kf_loc_0, &v_1232, &v_1233, 0), _fx_catch_249);
            FX_THROW(&v_1233, false, _fx_catch_249);

         _fx_catch_249: ;
            fx_free_exn(&v_1233);
            FX_FREE_STR(&v_1232);
            FX_FREE_STR(&v_1231);
            FX_FREE_STR(&v_1230);
         }
         FX_CHECK_EXN(_fx_catch_251);
         FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(fcv_t_0, &kf_loc_0, &v_1213),
            _fx_catch_251);
         FX_CALL(
            _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(f_id_0,
               _fx_g23C_form__std_CTypVoidPtr, &kloc_0, &v_1214, 0), _fx_catch_251);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1214, 0, true, &v_1215), _fx_catch_251);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(free_f_exp_4, v_1215, false, &v_1215), _fx_catch_251);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1213, v_1215, false, &v_1215), _fx_catch_251);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g33C_form__std_FX_MAKE_FP_IMPL_START, v_1215, _fx_g20C_gen_code__CTypVoid, &kf_loc_0, &alloc_fcv_0, 0),
            _fx_catch_251);
         _fx_R9Ast__id_t v_1234;
         fx_str_t slit_258 = FX_MAKE_STR("fcv");
         FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_258, &v_1234, 0), _fx_catch_251);
         FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(fcv_t_0, &v_1216, 0), _fx_catch_251);
         FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_1217, 0), _fx_catch_251);
         fx_str_t slit_259 = FX_MAKE_STR("fcv");
         FX_CALL(
            _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
               &v_1234, v_1216, &v_1217, &slit_259, &_fx_g18C_gen_code__None2_, 0, &kf_loc_0, &v_1218, 0), _fx_catch_251);
         FX_COPY_PTR(v_1218.t0, &fcv_exp_0);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kf_loc_0, &v_1219, 0), _fx_catch_251);
         _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1219, &v_1220);
         FX_CALL(
            _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_1220, &kf_loc_0, &v_1221),
            _fx_catch_251);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1221, 0, true, &ret_ccode_2), _fx_catch_251);
         FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(alloc_fcv_0, &v_1222), _fx_catch_251);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1222, 0, true, &ccode_200), _fx_catch_251);
         FX_COPY_PTR(ccode_200, &__fold_result___25);
         int_ idx_3 = 0;
         _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t lst_31 = real_args_0;
         for (; lst_31; lst_31 = lst_31->tl, idx_3 += 1) {
            _fx_N14C_form__ctyp_t t_27 = 0;
            _fx_LN19C_form__carg_attr_t flags_5 = 0;
            _fx_LN15C_form__cstmt_t ccode_202 = 0;
            _fx_N14C_form__cexp_t src_exp_4 = 0;
            _fx_T2N14C_form__cexp_tN14C_form__ctyp_t v_1235 = {0};
            _fx_N14C_form__cexp_t src_exp_5 = 0;
            _fx_N14C_form__ctyp_t t_28 = 0;
            fx_str_t v_1236 = {0};
            fx_str_t v_1237 = {0};
            _fx_N14C_form__cexp_t dst_exp_20 = 0;
            _fx_LN15C_form__cstmt_t v_1238 = 0;
            _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* __pat___13 = &lst_31->hd;
            _fx_R9Ast__id_t a_14 = __pat___13->t0;
            FX_COPY_PTR(__pat___13->t1, &t_27);
            FX_COPY_PTR(__pat___13->t2, &flags_5);
            FX_COPY_PTR(__fold_result___25, &ccode_202);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&a_14, t_27, &kf_loc_0,
                  &src_exp_4, 0), _fx_catch_250);
            FX_CALL(
               _fx_M10C_gen_codeFM19maybe_deref_fun_argT2N14C_form__cexp_tN14C_form__ctyp_t5iN14C_form__cexp_tN14C_form__ctyp_tLN19C_form__carg_attr_tR10Ast__loc_t(
                  idx_3, src_exp_4, t_27, flags_5, &kf_loc_0, &v_1235, 0), _fx_catch_250);
            FX_COPY_PTR(v_1235.t0, &src_exp_5);
            FX_COPY_PTR(v_1235.t1, &t_28);
            FX_CALL(_fx_F6stringS1i(idx_3, &v_1236, 0), _fx_catch_250);
            fx_str_t slit_260 = FX_MAKE_STR("t");
            {
               const fx_str_t strs_42[] = { slit_260, v_1236 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_42, 2, &v_1237), _fx_catch_250);
            }
            _fx_R9Ast__id_t fcv_elem_0;
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&v_1237, &fcv_elem_0, 0), _fx_catch_250);
            FX_CALL(
               _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(fcv_exp_0, &fcv_elem_0,
                  t_28, &dst_exp_20, 0), _fx_catch_250);
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  src_exp_5, dst_exp_20, t_28, ccode_202, &kf_loc_0, &v_1238, 0), _fx_catch_250);
            _fx_free_LN15C_form__cstmt_t(&__fold_result___25);
            FX_COPY_PTR(v_1238, &__fold_result___25);

         _fx_catch_250: ;
            if (v_1238) {
               _fx_free_LN15C_form__cstmt_t(&v_1238);
            }
            if (dst_exp_20) {
               _fx_free_N14C_form__cexp_t(&dst_exp_20);
            }
            FX_FREE_STR(&v_1237);
            FX_FREE_STR(&v_1236);
            if (t_28) {
               _fx_free_N14C_form__ctyp_t(&t_28);
            }
            if (src_exp_5) {
               _fx_free_N14C_form__cexp_t(&src_exp_5);
            }
            _fx_free_T2N14C_form__cexp_tN14C_form__ctyp_t(&v_1235);
            if (src_exp_4) {
               _fx_free_N14C_form__cexp_t(&src_exp_4);
            }
            if (ccode_202) {
               _fx_free_LN15C_form__cstmt_t(&ccode_202);
            }
            FX_FREE_LIST_SIMPLE(&flags_5);
            if (t_27) {
               _fx_free_N14C_form__ctyp_t(&t_27);
            }
            FX_CHECK_EXN(_fx_catch_251);
         }
         FX_COPY_PTR(__fold_result___25, &ccode_201);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(ret_ccode_2, ccode_201,
               &v_1223, 0), _fx_catch_251);
         FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(v_1223, &new_body_0, 0), _fx_catch_251);

      _fx_catch_251: ;
         if (v_1223) {
            _fx_free_LN15C_form__cstmt_t(&v_1223);
         }
         if (ccode_201) {
            _fx_free_LN15C_form__cstmt_t(&ccode_201);
         }
         if (__fold_result___25) {
            _fx_free_LN15C_form__cstmt_t(&__fold_result___25);
         }
         if (ccode_200) {
            _fx_free_LN15C_form__cstmt_t(&ccode_200);
         }
         if (v_1222) {
            _fx_free_N15C_form__cstmt_t(&v_1222);
         }
         if (ret_ccode_2) {
            _fx_free_LN15C_form__cstmt_t(&ret_ccode_2);
         }
         if (v_1221) {
            _fx_free_N15C_form__cstmt_t(&v_1221);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1220);
         if (v_1219) {
            _fx_free_N14C_form__cexp_t(&v_1219);
         }
         if (fcv_exp_0) {
            _fx_free_N14C_form__cexp_t(&fcv_exp_0);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1218);
         _fx_free_R16Ast__val_flags_t(&v_1217);
         if (v_1216) {
            _fx_free_N14C_form__ctyp_t(&v_1216);
         }
         if (alloc_fcv_0) {
            _fx_free_N14C_form__cexp_t(&alloc_fcv_0);
         }
         if (v_1215) {
            _fx_free_LN14C_form__cexp_t(&v_1215);
         }
         if (v_1214) {
            _fx_free_N14C_form__cexp_t(&v_1214);
         }
         if (v_1213) {
            _fx_free_N14C_form__cexp_t(&v_1213);
         }
         if (free_f_exp_4) {
            _fx_free_N14C_form__cexp_t(&free_f_exp_4);
         }
         _fx_free_T2BNt6option1N14C_form__cexp_t(&v_1212);
         if (fcv_t_0) {
            _fx_free_N14C_form__ctyp_t(&fcv_t_0);
         }
         _fx_free_N15K_form__kinfo_t(&v_1211);
         goto _fx_endmatch_48;
      }
      if (ctor_0.tag == 5) {
         _fx_N15C_form__cinfo_t v_1239 = {0};
         _fx_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t v_1240 = {0};
         _fx_N14C_form__ctyp_t exn_typ_0 = 0;
         _fx_N14C_form__ctyp_t exn_data_t_0 = 0;
         _fx_N14C_form__cexp_t v_1241 = 0;
         _fx_N14C_form__cexp_t v_1242 = 0;
         _fx_N14C_form__cexp_t v_1243 = 0;
         _fx_LN14C_form__cexp_t v_1244 = 0;
         _fx_N14C_form__cexp_t alloc_exn_data_0 = 0;
         _fx_N14C_form__cexp_t v_1245 = 0;
         _fx_Nt6option1N14C_form__cexp_t v_1246 = {0};
         _fx_N15C_form__cstmt_t v_1247 = 0;
         _fx_LN15C_form__cstmt_t ret_ccode_3 = 0;
         _fx_N14C_form__ctyp_t v_1248 = 0;
         _fx_N14C_form__cexp_t exn_data_2 = 0;
         _fx_N14C_form__cexp_t dst_exp_21 = 0;
         _fx_N15C_form__cstmt_t v_1249 = 0;
         _fx_LN15C_form__cstmt_t ccode_203 = 0;
         _fx_LN15C_form__cstmt_t __fold_result___26 = 0;
         _fx_LN15C_form__cstmt_t ccode_204 = 0;
         _fx_LN15C_form__cstmt_t v_1250 = 0;
         _fx_R9Ast__id_t* exn_id_0 = &ctor_0.u.CtorExn;
         FX_CALL(_fx_M6C_formFM6cinfo_N15C_form__cinfo_t2R9Ast__id_tR10Ast__loc_t(exn_id_0, &kf_loc_0, &v_1239, 0),
            _fx_catch_254);
         if (v_1239.tag == 5) {
            _fx_R17C_form__cdefexn_t v_1251 = {0};
            _fx_copy_R17C_form__cdefexn_t(&v_1239.u.CExn->data, &v_1251);
            _fx_make_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t(v_1251.cexn_typ, &v_1251.cexn_tag, v_1251.cexn_std,
               &v_1251.cexn_data, &v_1251.cexn_info, &v_1240);
            _fx_free_R17C_form__cdefexn_t(&v_1251);
         }
         else {
            fx_str_t v_1252 = {0};
            fx_str_t v_1253 = {0};
            fx_str_t v_1254 = {0};
            fx_exn_t v_1255 = {0};
            FX_CALL(_fx_M6K_formFM7idk2strS2R9Ast__id_tR10Ast__loc_t(exn_id_0, &kf_loc_0, &v_1252, 0), _fx_catch_252);
            FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1252, &v_1253, 0), _fx_catch_252);
            fx_str_t slit_261 = FX_MAKE_STR("cgen: constructor of exception \'");
            fx_str_t slit_262 = FX_MAKE_STR("\' is expecting converted KExn=>CExn structure");
            {
               const fx_str_t strs_43[] = { slit_261, v_1253, slit_262 };
               FX_CALL(fx_strjoin(0, 0, 0, strs_43, 3, &v_1254), _fx_catch_252);
            }
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kf_loc_0, &v_1254, &v_1255, 0), _fx_catch_252);
            FX_THROW(&v_1255, false, _fx_catch_252);

         _fx_catch_252: ;
            fx_free_exn(&v_1255);
            FX_FREE_STR(&v_1254);
            FX_FREE_STR(&v_1253);
            FX_FREE_STR(&v_1252);
         }
         FX_CHECK_EXN(_fx_catch_254);
         FX_COPY_PTR(v_1240.t0, &exn_typ_0);
         _fx_R9Ast__id_t exn_tag_0 = v_1240.t1;
         bool exn_std_0 = v_1240.t2;
         _fx_R9Ast__id_t exn_data_id_0 = v_1240.t3;
         _fx_R9Ast__id_t exn_info_0 = v_1240.t4;
         if (exn_std_0) {
            FX_COPY_PTR(ccode_0, &new_body_0);
         }
         else {
            FX_CALL(_fx_M6C_formFM8CTypNameN14C_form__ctyp_t1R9Ast__id_t(&exn_data_id_0, &exn_data_t_0), _fx_catch_254);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&exn_tag_0,
                  _fx_g20C_gen_code__CTypCInt, &kf_loc_0, &v_1241, 0), _fx_catch_254);
            FX_CALL(_fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(exn_data_t_0, &kf_loc_0, &v_1242),
               _fx_catch_254);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&exn_info_0,
                  _fx_g25C_form__std_fx_exn_info_t, &kf_loc_0, &v_1243, 0), _fx_catch_254);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1243, 0, true, &v_1244), _fx_catch_254);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1242, v_1244, false, &v_1244), _fx_catch_254);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(v_1241, v_1244, false, &v_1244), _fx_catch_254);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g34C_form__std_FX_MAKE_EXN_IMPL_START, v_1244, _fx_g20C_gen_code__CTypVoid, &kf_loc_0, &alloc_exn_data_0,
                  0), _fx_catch_254);
            FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &kf_loc_0, &v_1245, 0), _fx_catch_254);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_1245, &v_1246);
            FX_CALL(
               _fx_M6C_formFM11CStmtReturnN15C_form__cstmt_t2Nt6option1N14C_form__cexp_tR10Ast__loc_t(&v_1246, &kf_loc_0,
                  &v_1247), _fx_catch_254);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1247, 0, true, &ret_ccode_3), _fx_catch_254);
            _fx_R9Ast__id_t v_1256;
            fx_str_t slit_263 = FX_MAKE_STR("exn_data");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_263, &v_1256, 0), _fx_catch_254);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(exn_data_t_0, &v_1248, 0), _fx_catch_254);
            FX_CALL(
               _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&v_1256, v_1248,
                  &kf_loc_0, &exn_data_2, 0), _fx_catch_254);
            _fx_R9Ast__id_t v_1257;
            fx_str_t slit_264 = FX_MAKE_STR("data");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_264, &v_1257, 0), _fx_catch_254);
            FX_CALL(
               _fx_M6C_formFM10cexp_arrowN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(exn_data_2, &v_1257,
                  exn_typ_0, &dst_exp_21, 0), _fx_catch_254);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(alloc_exn_data_0, &v_1249), _fx_catch_254);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_1249, 0, true, &ccode_203), _fx_catch_254);
            FX_COPY_PTR(ccode_203, &__fold_result___26);
            int_ idx_4 = 0;
            _fx_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t lst_32 = real_args_0;
            for (; lst_32; lst_32 = lst_32->tl, idx_4 += 1) {
               _fx_N14C_form__ctyp_t t_29 = 0;
               _fx_LN19C_form__carg_attr_t flags_6 = 0;
               _fx_LN15C_form__cstmt_t ccode_205 = 0;
               _fx_N14C_form__cexp_t src_exp_6 = 0;
               _fx_T2N14C_form__cexp_tN14C_form__ctyp_t v_1258 = {0};
               _fx_N14C_form__cexp_t src_exp_7 = 0;
               _fx_N14C_form__ctyp_t t_30 = 0;
               _fx_N14C_form__cexp_t dst_exp_22 = 0;
               fx_str_t v_1259 = {0};
               fx_str_t v_1260 = {0};
               _fx_LN15C_form__cstmt_t v_1261 = 0;
               _fx_T3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t* __pat___14 = &lst_32->hd;
               _fx_R9Ast__id_t a_15 = __pat___14->t0;
               FX_COPY_PTR(__pat___14->t1, &t_29);
               FX_COPY_PTR(__pat___14->t2, &flags_6);
               FX_COPY_PTR(__fold_result___26, &ccode_205);
               FX_CALL(
                  _fx_M6C_formFM13make_id_t_expN14C_form__cexp_t3R9Ast__id_tN14C_form__ctyp_tR10Ast__loc_t(&a_15, t_29,
                     &kf_loc_0, &src_exp_6, 0), _fx_catch_253);
               FX_CALL(
                  _fx_M10C_gen_codeFM19maybe_deref_fun_argT2N14C_form__cexp_tN14C_form__ctyp_t5iN14C_form__cexp_tN14C_form__ctyp_tLN19C_form__carg_attr_tR10Ast__loc_t(
                     idx_4, src_exp_6, t_29, flags_6, &kf_loc_0, &v_1258, 0), _fx_catch_253);
               FX_COPY_PTR(v_1258.t0, &src_exp_7);
               FX_COPY_PTR(v_1258.t1, &t_30);
               if (nreal_args_0 == 1) {
                  FX_COPY_PTR(dst_exp_21, &dst_exp_22);
               }
               else {
                  FX_CALL(_fx_F6stringS1i(idx_4, &v_1259, 0), _fx_catch_253);
                  fx_str_t slit_265 = FX_MAKE_STR("t");
                  {
                     const fx_str_t strs_44[] = { slit_265, v_1259 };
                     FX_CALL(fx_strjoin(0, 0, 0, strs_44, 2, &v_1260), _fx_catch_253);
                  }
                  _fx_R9Ast__id_t t_elem_0;
                  FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&v_1260, &t_elem_0, 0), _fx_catch_253);
                  FX_CALL(
                     _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(dst_exp_21,
                        &t_elem_0, t_30, &dst_exp_22, 0), _fx_catch_253);
               }
               FX_CALL(
                  _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                     src_exp_7, dst_exp_22, t_30, ccode_205, &kf_loc_0, &v_1261, 0), _fx_catch_253);
               _fx_free_LN15C_form__cstmt_t(&__fold_result___26);
               FX_COPY_PTR(v_1261, &__fold_result___26);

            _fx_catch_253: ;
               if (v_1261) {
                  _fx_free_LN15C_form__cstmt_t(&v_1261);
               }
               FX_FREE_STR(&v_1260);
               FX_FREE_STR(&v_1259);
               if (dst_exp_22) {
                  _fx_free_N14C_form__cexp_t(&dst_exp_22);
               }
               if (t_30) {
                  _fx_free_N14C_form__ctyp_t(&t_30);
               }
               if (src_exp_7) {
                  _fx_free_N14C_form__cexp_t(&src_exp_7);
               }
               _fx_free_T2N14C_form__cexp_tN14C_form__ctyp_t(&v_1258);
               if (src_exp_6) {
                  _fx_free_N14C_form__cexp_t(&src_exp_6);
               }
               if (ccode_205) {
                  _fx_free_LN15C_form__cstmt_t(&ccode_205);
               }
               FX_FREE_LIST_SIMPLE(&flags_6);
               if (t_29) {
                  _fx_free_N14C_form__ctyp_t(&t_29);
               }
               FX_CHECK_EXN(_fx_catch_254);
            }
            FX_COPY_PTR(__fold_result___26, &ccode_204);
            FX_CALL(
               _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(ret_ccode_3, ccode_204,
                  &v_1250, 0), _fx_catch_254);
            FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(v_1250, &new_body_0, 0), _fx_catch_254);
         }

      _fx_catch_254: ;
         if (v_1250) {
            _fx_free_LN15C_form__cstmt_t(&v_1250);
         }
         if (ccode_204) {
            _fx_free_LN15C_form__cstmt_t(&ccode_204);
         }
         if (__fold_result___26) {
            _fx_free_LN15C_form__cstmt_t(&__fold_result___26);
         }
         if (ccode_203) {
            _fx_free_LN15C_form__cstmt_t(&ccode_203);
         }
         if (v_1249) {
            _fx_free_N15C_form__cstmt_t(&v_1249);
         }
         if (dst_exp_21) {
            _fx_free_N14C_form__cexp_t(&dst_exp_21);
         }
         if (exn_data_2) {
            _fx_free_N14C_form__cexp_t(&exn_data_2);
         }
         if (v_1248) {
            _fx_free_N14C_form__ctyp_t(&v_1248);
         }
         if (ret_ccode_3) {
            _fx_free_LN15C_form__cstmt_t(&ret_ccode_3);
         }
         if (v_1247) {
            _fx_free_N15C_form__cstmt_t(&v_1247);
         }
         _fx_free_Nt6option1N14C_form__cexp_t(&v_1246);
         if (v_1245) {
            _fx_free_N14C_form__cexp_t(&v_1245);
         }
         if (alloc_exn_data_0) {
            _fx_free_N14C_form__cexp_t(&alloc_exn_data_0);
         }
         if (v_1244) {
            _fx_free_LN14C_form__cexp_t(&v_1244);
         }
         if (v_1243) {
            _fx_free_N14C_form__cexp_t(&v_1243);
         }
         if (v_1242) {
            _fx_free_N14C_form__cexp_t(&v_1242);
         }
         if (v_1241) {
            _fx_free_N14C_form__cexp_t(&v_1241);
         }
         if (exn_data_t_0) {
            _fx_free_N14C_form__ctyp_t(&exn_data_t_0);
         }
         if (exn_typ_0) {
            _fx_free_N14C_form__ctyp_t(&exn_typ_0);
         }
         _fx_free_T5N14C_form__ctyp_tR9Ast__id_tBR9Ast__id_tR9Ast__id_t(&v_1240);
         _fx_free_N15C_form__cinfo_t(&v_1239);
         goto _fx_endmatch_48;
      }
      fx_str_t v_1262 = {0};
      fx_str_t v_1263 = {0};
      fx_str_t v_1264 = {0};
      fx_str_t v_1265 = {0};
      fx_exn_t v_1266 = {0};
      FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&kf_cname_0, &v_1262, 0), _fx_catch_255);
      FX_CALL(_fx_M3AstFM8ctor2strS1N17Ast__fun_constr_t(&ctor_0, &v_1263, 0), _fx_catch_255);
      FX_CALL(_fx_M10C_gen_codeFM6stringS1S(&v_1263, &v_1264, 0), _fx_catch_255);
      fx_str_t slit_266 = FX_MAKE_STR("cgen: unsupported type of constructor ");
      fx_str_t slit_267 = FX_MAKE_STR(": ");
      {
         const fx_str_t strs_45[] = { slit_266, v_1262, slit_267, v_1264 };
         FX_CALL(fx_strjoin(0, 0, 0, strs_45, 4, &v_1265), _fx_catch_255);
      }
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&kloc_0, &v_1265, &v_1266, 0), _fx_catch_255);
      FX_THROW(&v_1266, false, _fx_catch_255);

   _fx_catch_255: ;
      fx_free_exn(&v_1266);
      FX_FREE_STR(&v_1265);
      FX_FREE_STR(&v_1264);
      FX_FREE_STR(&v_1263);
      FX_FREE_STR(&v_1262);

   _fx_endmatch_48: ;
      FX_CHECK_EXN(_fx_catch_256);
      FX_CALL(_fx_M10C_gen_codeFM13pop_block_ctxv2R10Ast__loc_trLrRM11block_ctx_t(&kloc_0, block_stack_ref_0, 0),
         _fx_catch_256);
      _fx_R16Ast__fun_flags_t* v_1267 = &cf_0->data.cf_flags;
      _fx_R16Ast__fun_flags_t new_cf_flags_0 =
         { v_1267->fun_flag_pure, v_1267->fun_flag_ccode, v_1267->fun_flag_have_keywords, v_1267->fun_flag_inline,
            v_1267->fun_flag_nothrow, really_nothrow_0->data, v_1267->fun_flag_private, v_1267->fun_flag_ctor,
            v_1267->fun_flag_method_of, v_1267->fun_flag_uses_fv, v_1267->fun_flag_recursive, v_1267->fun_flag_instance };
      _fx_R17C_form__cdeffun_t* v_1268 = &cf_0->data;
      FX_CALL(_fx_M6C_formFM15filter_out_nopsLN15C_form__cstmt_t1LN15C_form__cstmt_t(new_body_0, &v_1120, 0), _fx_catch_256);
      _fx_make_R17C_form__cdeffun_t(&v_1268->cf_name, &v_1268->cf_cname, v_1268->cf_args, v_1268->cf_rt, v_1120,
         &new_cf_flags_0, v_1268->cf_scope, &v_1268->cf_loc, &v_1121);
      _fx_R17C_form__cdeffun_t* v_1269 = &cf_0->data;
      _fx_free_R17C_form__cdeffun_t(v_1269);
      _fx_copy_R17C_form__cdeffun_t(&v_1121, v_1269);
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1);

   _fx_catch_256: ;
      _fx_free_R17C_form__cdeffun_t(&v_1121);
      if (v_1120) {
         _fx_free_LN15C_form__cstmt_t(&v_1120);
      }
      if (new_body_0) {
         _fx_free_LN15C_form__cstmt_t(&new_body_0);
      }
      FX_FREE_REF_SIMPLE(&really_nothrow_0);
      if (real_args_0) {
         _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&real_args_0);
      }
      _fx_free_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tR9Ast__id_tN14C_form__ctyp_tB(&v_1119);
      if (cf_0) {
         _fx_free_rR17C_form__cdeffun_t(&cf_0);
      }
      if (rt_0) {
         _fx_free_N14C_form__ctyp_t(&rt_0);
      }
      if (args_17) {
         _fx_free_LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_t(&args_17);
      }
      _fx_free_T4LT3R9Ast__id_tN14C_form__ctyp_tLN19C_form__carg_attr_tN14C_form__ctyp_tBrR17C_form__cdeffun_t(&v_1118);
      _fx_free_N15C_form__cinfo_t(&v_1117);
      if (kf_rt_0) {
         _fx_free_N14K_form__ktyp_t(&kf_rt_0);
      }
      if (kf_body_0) {
         _fx_free_N14K_form__kexp_t(&kf_body_0);
      }
      FX_FREE_STR(&kf_cname_0);
      goto _fx_endmatch_49;
   }
   if (tag_0 == 33) {
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1); goto _fx_endmatch_49;
   }
   if (tag_0 == 34) {
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1); goto _fx_endmatch_49;
   }
   if (tag_0 == 36) {
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1); goto _fx_endmatch_49;
   }
   if (tag_0 == 35) {
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1); goto _fx_endmatch_49;
   }
   if (tag_0 == 37) {
      _fx_make_T3BN14C_form__cexp_tLN15C_form__cstmt_t(false, dummy_exp_0, ccode_0, &v_1); goto _fx_endmatch_49;
   }
   FX_FAST_THROW(FX_EXN_NoMatchError, _fx_cleanup);

_fx_endmatch_49: ;
   FX_CHECK_EXN(_fx_cleanup);
   bool assign_0 = v_1.t0;
   FX_COPY_PTR(v_1.t1, &result_exp_0);
   FX_COPY_PTR(v_1.t2, &ccode_1);
   bool t_31;
   if (!assign_0) {
      t_31 = true;
   }
   else {
      t_31 = FX_REC_VARIANT_TAG(ctyp_0) == 8;
   }
   if (t_31) {
      _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(result_exp_0, ccode_1, fx_result);
   }
   else {
      _fx_copy_Nt6option1N14C_form__cexp_t(&dstexp_r_0->data, &v_2);
      if (v_2.tag == 2) {
         _fx_LN15C_form__cstmt_t ccode_206 = 0;
         _fx_N14C_form__cexp_t dst_exp_23 = v_2.u.Some;
         bool skip_copy_0;
         if (FX_REC_VARIANT_TAG(result_exp_0) == 2) {
            if (result_exp_0->u.CExpLit.t0.tag == 8) {
               _fx_R17C_form__ctprops_t v_1270 = {0};
               FX_CALL(
                  _fx_M11C_gen_typesFM11get_ctpropsR17C_form__ctprops_t2N14C_form__ctyp_tR10Ast__loc_t(ctyp_0, &kloc_0, &v_1270,
                     0), _fx_catch_257);
               skip_copy_0 = v_1270.ctp_ptr;

            _fx_catch_257: ;
               _fx_free_R17C_form__ctprops_t(&v_1270);
               goto _fx_endmatch_50;
            }
         }
         skip_copy_0 = false;

      _fx_endmatch_50: ;
         FX_CHECK_EXN(_fx_catch_258);
         if (skip_copy_0) {
            FX_COPY_PTR(ccode_1, &ccode_206);
         }
         else {
            FX_CALL(
               _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  result_exp_0, dst_exp_23, ctyp_0, ccode_1, &kloc_0, &ccode_206, 0), _fx_catch_258);
         }
         _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(dst_exp_23, ccode_206, fx_result);

      _fx_catch_258: ;
         if (ccode_206) {
            _fx_free_LN15C_form__cstmt_t(&ccode_206);
         }
      }
      else {
         _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(result_exp_0, ccode_1, fx_result);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }

_fx_cleanup: ;
   FX_FREE_FP(&atom2cexp_0);
   FX_FREE_FP(&atom2cexp__0);
   FX_FREE_FP(&process_cases_0);
   FX_FREE_FP(&process_for_0);
   _fx_free_T2N14K_form__ktyp_tR10Ast__loc_t(&v_0);
   if (ktyp_0) {
      _fx_free_N14K_form__ktyp_t(&ktyp_0);
   }
   if (ctyp_0) {
      _fx_free_N14C_form__ctyp_t(&ctyp_0);
   }
   if (dummy_exp_0) {
      _fx_free_N14C_form__cexp_t(&dummy_exp_0);
   }
   _fx_free_T3BN14C_form__cexp_tLN15C_form__cstmt_t(&v_1);
   if (result_exp_0) {
      _fx_free_N14C_form__cexp_t(&result_exp_0);
   }
   if (ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&ccode_1);
   }
   _fx_free_Nt6option1N14C_form__cexp_t(&v_2);
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t*
      fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t,
      _fx_free_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t,
      _fx_M10C_gen_codeFM9kexp2cexpT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

static int _fx_M10C_gen_codeFM10handle_idxN14K_form__atom_t2N14K_form__atom_tl(
   struct _fx_N14K_form__atom_t* range_idx_0,
   int64_t deflt_0,
   struct _fx_N14K_form__atom_t* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (range_idx_0->tag == 2) {
      if (range_idx_0->u.AtomLit.tag == 8) {
         _fx_N14K_form__klit_t v_0 = {0};
         _fx_M6K_formFM7KLitIntN14K_form__klit_t1l(deflt_0, &v_0);
         _fx_M6K_formFM7AtomLitN14K_form__atom_t1N14K_form__klit_t(&v_0, fx_result);
         _fx_free_N14K_form__klit_t(&v_0);
         goto _fx_endmatch_0;
      }
   }
   _fx_copy_N14K_form__atom_t(range_idx_0, fx_result);

_fx_endmatch_0: ;
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t(
   struct _fx_LN14K_form__kexp_t_data_t* el_0,
   struct _fx_LN15C_form__cstmt_t_data_t* ccode_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_rNt6option1N14C_form__cexp_t_data_t* dstexp_r_0,
   struct _fx_N14C_form__cexp_t_data_t* dummy_exp_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   int_ km_idx_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   struct _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t
      kexp2cexp_0 = {0};
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t result_0 = {0};
   _fx_LN14K_form__kexp_t el_1 = 0;
   _fx_LN15C_form__cstmt_t ccode_1 = 0;
   int fx_status = 0;
   _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t*)
         fx_fv;
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      cv_0->t0, cv_0->t1, cv_0->t2, cv_0->t3, cv_0->t4, &kexp2cexp_0);
   FX_COPY_PTR(el_0, &el_1);
   FX_COPY_PTR(ccode_0, &ccode_1);
   for (;;) {
      _fx_LN14K_form__kexp_t el_2 = 0;
      _fx_LN15C_form__cstmt_t ccode_2 = 0;
      FX_COPY_PTR(el_1, &el_2);
      FX_COPY_PTR(ccode_1, &ccode_2);
      if (el_2 == 0) {
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t result_1 = {0};
         _fx_make_T2N14C_form__cexp_tLN15C_form__cstmt_t(dummy_exp_0, ccode_2, &result_1);
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_0);
         _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_1, &result_0);
         FX_BREAK(_fx_catch_0);

      _fx_catch_0: ;
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_1);
         goto _fx_endmatch_0;
      }
      if (el_2 != 0) {
         if (el_2->tl == 0) {
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t result_2 = {0};
            FX_CALL(
               kexp2cexp_0.fp(el_2->hd, dstexp_r_0, ccode_2, block_stack_ref_0, defined_syms_ref_0, for_letters_0,
                  func_dstexp_r_ref_0, fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0,
                  module_cleanup_ref_0, return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &result_2, kexp2cexp_0.fcv),
               _fx_catch_1);
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_0);
            _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_2, &result_0);
            FX_BREAK(_fx_catch_1);

         _fx_catch_1: ;
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_2);
            goto _fx_endmatch_0;
         }
      }
      if (el_2 != 0) {
         _fx_rNt6option1N14C_form__cexp_t v_0 = 0;
         _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_1 = {0};
         _fx_LN15C_form__cstmt_t ccode_3 = 0;
         FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_0), _fx_catch_2);
         FX_CALL(
            kexp2cexp_0.fp(el_2->hd, v_0, ccode_2, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
               fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
               return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_1, kexp2cexp_0.fcv), _fx_catch_2);
         FX_COPY_PTR(v_1.t1, &ccode_3);
         _fx_LN14K_form__kexp_t* rest_0 = &el_2->tl;
         _fx_free_LN14K_form__kexp_t(&el_1);
         FX_COPY_PTR(*rest_0, &el_1);
         _fx_free_LN15C_form__cstmt_t(&ccode_1);
         FX_COPY_PTR(ccode_3, &ccode_1);

      _fx_catch_2: ;
         if (ccode_3) {
            _fx_free_LN15C_form__cstmt_t(&ccode_3);
         }
         _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_1);
         if (v_0) {
            _fx_free_rNt6option1N14C_form__cexp_t(&v_0);
         }
         goto _fx_endmatch_0;
      }
      FX_FAST_THROW(FX_EXN_NoMatchError, _fx_catch_3);

   _fx_endmatch_0: ;
      FX_CHECK_EXN(_fx_catch_3);

   _fx_catch_3: ;
      if (ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&ccode_2);
      }
      if (el_2) {
         _fx_free_LN14K_form__kexp_t(&el_2);
      }
      FX_CHECK_BREAK();
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_0, fx_result);

_fx_cleanup: ;
   FX_FREE_FP(&kexp2cexp_0);
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&result_0);
   if (el_1) {
      _fx_free_LN14K_form__kexp_t(&el_1);
   }
   if (ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&ccode_1);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t*
      fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t_cldata_t,
      _fx_free_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t,
      _fx_M10C_gen_codeFM11process_seqT2N14C_form__cexp_tLN15C_form__cstmt_t18LN14K_form__kexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trNt6option1N14C_form__cexp_tN14C_form__cexp_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

static int _fx_M10C_gen_codeFM16check_range_elemB3N14K_form__atom_tNt10Hashset__t1R9Ast__id_tR10Ast__loc_t(
   struct _fx_N14K_form__atom_t* abd_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* decl_inside_for_0,
   struct _fx_R10Ast__loc_t* kloc_0,
   bool* fx_result,
   void* fx_fv)
{
   int fx_status = 0;
   if (abd_0->tag == 1) {
      _fx_R9Ast__id_t* k_0 = &abd_0->u.AtomId;
      bool v_0;
      FX_CALL(_fx_M6K_formFM10is_mutableB2R9Ast__id_tR10Ast__loc_t(k_0, kloc_0, &v_0, 0), _fx_catch_0);
      if (!v_0) {
         uint64_t __fold_result___0 = 14695981039346656037ULL;
         uint64_t h_0 = __fold_result___0 ^ ((uint64_t)k_0->m ^ 14695981039346656037ULL);
         __fold_result___0 = h_0 * 1099511628211ULL;
         uint64_t h_1 = __fold_result___0 ^ ((uint64_t)k_0->i ^ 14695981039346656037ULL);
         __fold_result___0 = h_1 * 1099511628211ULL;
         uint64_t h_2 = __fold_result___0 ^ ((uint64_t)k_0->j ^ 14695981039346656037ULL);
         __fold_result___0 = h_2 * 1099511628211ULL;
         _fx_Ta2i v_1;
         FX_CALL(
            _fx_M10C_gen_codeFM9find_idx_Ta2i3Nt10Hashset__t1R9Ast__id_tR9Ast__id_tq(decl_inside_for_0, k_0,
               __fold_result___0 & 9223372036854775807ULL, &v_1, 0), _fx_catch_0);
         *fx_result = !(v_1.t1 >= 0);
      }
      else {
         *fx_result = false;
      }

   _fx_catch_0: ;
   }
   else {
      *fx_result = true;
   }
   return fx_status;
}

static int
   _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB(
   struct _fx_LN15C_form__cstmt_t_data_t* pre_map_ccode_0,
   int_ for_idx_0,
   struct _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t_data_t* e_idoml_l_0,
   struct _fx_LN14C_form__cexp_t_data_t* prev_i_exps_0,
   struct _fx_LN14C_form__cexp_t_data_t* prev_n_exps_0,
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* block_stack_ref_0,
   struct _fx_LN15C_form__cstmt_t_data_t* decl_nested_status_0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* defined_syms_ref_0,
   struct _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t_data_t* dst_data_0,
   struct _fx_R10Ast__loc_t* end_for_loc_0,
   struct _fx_N15Ast__for_make_t* for_flag_make_0,
   struct _fx_LS_data_t* for_letters_0,
   struct _fx_R10Ast__loc_t* for_loc_0,
   struct _fx_rrNt6option1N14C_form__cexp_t_data_t* func_dstexp_r_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* fwd_fdecls_ref_0,
   struct _fx_R9Ast__id_t* fx_status__0,
   struct _fx_rLN15C_form__cstmt_t_data_t* glob_data_ccode_ref_0,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* i2e_ref_0,
   bool is_parallel_map_0,
   struct _fx_R10Ast__loc_t* kloc_0,
   int_ km_idx_0,
   struct _fx_N14C_form__cexp_t_data_t* map_lbl_0,
   struct _fx_LN12Ast__scope_t_data_t* mod_sc_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* module_cleanup_ref_0,
   int_ ndims_0,
   bool need_make_array_0,
   struct _fx_N14C_form__cexp_t_data_t* nested_status_0,
   int_ nfors_0,
   struct _fx_N14C_form__cexp_t_data_t* par_status_0,
   bool pre_alloc_array_0,
   struct _fx_ri_data_t* return_used_ref_0,
   struct _fx_rLN15C_form__cstmt_t_data_t* top_inline_ccode_ref_0,
   struct _fx_Nt10Hashset__t1R9Ast__id_t_data_t* u1vals_0,
   bool unzip_mode_0,
   struct _fx_Ta2LN15C_form__cstmt_t* fx_result,
   void* fx_fv)
{
   _fx_FPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t
      kexp2cexp_0 = {0};
   _fx_FPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrR23C_gen_code__block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti
      process_for_0 = {0};
   _fx_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t
      v_0 = {0};
   _fx_N14K_form__kexp_t init_kexp_0 = 0;
   _fx_LT2R9Ast__id_tN13K_form__dom_t idoml_0 = 0;
   _fx_LR9Ast__id_t at_ids_0 = 0;
   _fx_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t nested_e_idoml_0 = 0;
   _fx_rNt6option1N14C_form__cexp_t v_1 = 0;
   _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_2 = {0};
   _fx_LN15C_form__cstmt_t init_ccode_0 = 0;
   _fx_N14C_form__cexp_t lbl_0 = 0;
   _fx_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t
      v_3 = {0};
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t for_headers_0 = 0;
   _fx_LN14C_form__cexp_t list_exps_0 = 0;
   _fx_LN14C_form__cexp_t i_exps_0 = 0;
   _fx_LN14C_form__cexp_t n_exps_0 = 0;
   _fx_LN15C_form__cstmt_t pre_map_ccode_delta_0 = 0;
   _fx_LN15C_form__cstmt_t pre_body_ccode_0 = 0;
   _fx_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t body_elems_0 = 0;
   _fx_LN15C_form__cstmt_t post_ccode_0 = 0;
   _fx_T3iLN14C_form__cexp_tLN15C_form__cstmt_t v_4 = {0};
   _fx_LN14C_form__cexp_t n_exps_1 = 0;
   _fx_LN15C_form__cstmt_t lst_len_ccode_0 = 0;
   _fx_LN14C_form__cexp_t n_exps_2 = 0;
   _fx_LN14C_form__cexp_t i_exps_1 = 0;
   _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_5 = {0};
   _fx_N14C_form__cexp_t dst_exp0_0 = 0;
   _fx_LN15C_form__cstmt_t alloc_array_ccode_0 = 0;
   _fx_T2iLN14C_form__cexp_t __fold_result___0 = {0};
   _fx_T2iLN14C_form__cexp_t v_6 = {0};
   _fx_LN14C_form__cexp_t cmp_size_list_0 = 0;
   _fx_N14C_form__cexp_t lbl_1 = 0;
   _fx_LN15C_form__cstmt_t __fold_result___1 = 0;
   _fx_LN15C_form__cstmt_t then_ccode_0 = 0;
   _fx_N14C_form__cexp_t cc_exp_0 = 0;
   _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_7 = {0};
   _fx_N14C_form__cexp_t cc_exp_1 = 0;
   _fx_LN15C_form__cstmt_t else_ccode_0 = 0;
   _fx_N15C_form__cstmt_t v_8 = 0;
   _fx_N15C_form__cstmt_t v_9 = 0;
   _fx_N15C_form__cstmt_t check_or_create_0 = 0;
   _fx_Ta2LN15C_form__cstmt_t v_10 = {0};
   _fx_LN15C_form__cstmt_t v_11 = 0;
   _fx_LN15C_form__cstmt_t v_12 = 0;
   _fx_LN15C_form__cstmt_t v_13 = 0;
   _fx_LN15C_form__cstmt_t v_14 = 0;
   _fx_LN15C_form__cstmt_t v_15 = 0;
   _fx_LN15C_form__cstmt_t v_16 = 0;
   _fx_LN15C_form__cstmt_t pre_map_ccode_1 = 0;
   _fx_LN15C_form__cstmt_t init_ccode_1 = 0;
   _fx_LN15C_form__cstmt_t body_ccode_0 = 0;
   _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t
      v_17 = {0};
   _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_1 = 0;
   _fx_LN15C_form__cstmt_t pre_body_ccode_1 = 0;
   _fx_LN15C_form__cstmt_t pre_map_ccode_2 = 0;
   _fx_LN15C_form__cstmt_t body_ccode_1 = 0;
   _fx_T2R9Ast__id_tN15C_form__cstmt_t v_18 = {0};
   _fx_N15C_form__cstmt_t body_stmt_0 = 0;
   _fx_LN15C_form__cstmt_t v_19 = 0;
   _fx_LN15C_form__cstmt_t __fold_result___2 = 0;
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t v_20 = 0;
   _fx_LN15C_form__cstmt_t for_ccode_0 = 0;
   _fx_LN15C_form__cstmt_t post_ccode_1 = 0;
   _fx_N15C_form__cstmt_t v_21 = 0;
   _fx_LN15C_form__cstmt_t v_22 = 0;
   _fx_LN15C_form__cstmt_t v_23 = 0;
   int fx_status = 0;
   FX_CALL(fx_check_stack(), _fx_cleanup);
   _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB_cldata_t*
      cv_0 =
      (_fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB_cldata_t*)
         fx_fv;
   _fx_rLrR23C_gen_code__block_ctx_t block_stack_ref_1 = cv_0->t0;
   _fx_rNt10Hashset__t1R9Ast__id_t defined_syms_ref_1 = cv_0->t1;
   _fx_rLN15C_form__cstmt_t fwd_fdecls_ref_1 = cv_0->t2;
   _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t i2e_ref_1 = cv_0->t3;
   int_* km_idx_1 = &cv_0->t4;
   _fx_M10C_gen_codeFM7make_fpFPT2N14C_form__cexp_tLN15C_form__cstmt_t17N14K_form__kexp_trNt6option1N14C_form__cexp_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tiLN12Ast__scope_trLN15C_form__cstmt_trirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_t5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &kexp2cexp_0);
   _fx_M10C_gen_codeFM7make_fpFPT8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t16N14C_form__cexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tiiiiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_tLSrLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
      block_stack_ref_1, defined_syms_ref_1, fwd_fdecls_ref_1, i2e_ref_1, *km_idx_1, &process_for_0);
   if (e_idoml_l_0 != 0) {
      _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* v_24 = &e_idoml_l_0->hd;
      _fx_make_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
         v_24->t0, v_24->t1, v_24->t2, e_idoml_l_0->tl, &v_0);
   }
   else {
      fx_exn_t v_25 = {0};
      fx_str_t slit_0 = FX_MAKE_STR("cgen: empty e_idoml_l in KExpMap");
      FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(for_loc_0, &slit_0, &v_25, 0), _fx_catch_0);
      FX_THROW(&v_25, false, _fx_catch_0);

   _fx_catch_0: ;
      fx_free_exn(&v_25);
   }
   FX_CHECK_EXN(_fx_cleanup);
   FX_COPY_PTR(v_0.t0, &init_kexp_0);
   FX_COPY_PTR(v_0.t1, &idoml_0);
   FX_COPY_PTR(v_0.t2, &at_ids_0);
   FX_COPY_PTR(v_0.t3, &nested_e_idoml_0);
   int_ dims_ofs_0;
   FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(prev_n_exps_0, &dims_ofs_0, 0), _fx_cleanup);
   _fx_R10Ast__loc_t nested_loc_0;
   FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(init_kexp_0, &nested_loc_0, 0), _fx_cleanup);
   bool res_0;
   FX_CALL(_fx_M10C_gen_codeFM6__eq__B2R10Ast__loc_tR10Ast__loc_t(&nested_loc_0, &_fx_g10Ast__noloc, &res_0, 0), _fx_cleanup);
   _fx_R10Ast__loc_t nested_loc_1;
   if (res_0) {
      nested_loc_1 = *for_loc_0;
   }
   else {
      nested_loc_1 = nested_loc_0;
   }
   FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_1), _fx_cleanup);
   FX_CALL(
      kexp2cexp_0.fp(init_kexp_0, v_1, 0, block_stack_ref_0, defined_syms_ref_0, for_letters_0, func_dstexp_r_ref_0,
         fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0, module_cleanup_ref_0,
         return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_2, kexp2cexp_0.fcv), _fx_cleanup);
   FX_COPY_PTR(v_2.t1, &init_ccode_0);
   FX_CALL(
      _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&nested_loc_1, block_stack_ref_0,
         &lbl_0, 0), _fx_cleanup);
   FX_CALL(
      process_for_0.fp(lbl_0, idoml_0, at_ids_0, for_idx_0, nfors_0, ndims_0, dims_ofs_0, nested_e_idoml_0, 0, &nested_loc_1,
         block_stack_ref_0, defined_syms_ref_0, for_letters_0, fwd_fdecls_ref_0, i2e_ref_0, km_idx_0, &v_3, process_for_0.fcv),
      _fx_cleanup);
   FX_COPY_PTR(v_3.t0, &for_headers_0);
   FX_COPY_PTR(v_3.t1, &list_exps_0);
   FX_COPY_PTR(v_3.t2, &i_exps_0);
   FX_COPY_PTR(v_3.t3, &n_exps_0);
   FX_COPY_PTR(v_3.t4, &pre_map_ccode_delta_0);
   FX_COPY_PTR(v_3.t5, &pre_body_ccode_0);
   FX_COPY_PTR(v_3.t6, &body_elems_0);
   FX_COPY_PTR(v_3.t7, &post_ccode_0);
   if (n_exps_0 != 0) {
      int_ v_26;
      FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(n_exps_0, &v_26, 0), _fx_catch_1);
      _fx_make_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(v_26, n_exps_0, 0, &v_4);

   _fx_catch_1: ;
      goto _fx_endmatch_0;
   }
   if (need_make_array_0 == true) {
      if (n_exps_0 == 0) {
         if (list_exps_0 != 0) {
            _fx_LN14C_form__cexp_t v_27 = 0;
            _fx_N14C_form__cexp_t call_list_len_0 = 0;
            _fx_R16Ast__val_flags_t v_28 = {0};
            _fx_Nt6option1N14C_form__cexp_t v_29 = {0};
            _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_30 = {0};
            _fx_N14C_form__cexp_t lstlen_0 = 0;
            _fx_LN15C_form__cstmt_t lst_len_ccode_1 = 0;
            _fx_LN14C_form__cexp_t v_31 = 0;
            FX_CALL(_fx_cons_LN14C_form__cexp_t(list_exps_0->hd, 0, true, &v_27), _fx_catch_2);
            FX_CALL(
               _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g26C_form__std_fx_list_length, v_27, _fx_g19C_gen_code__CTypInt, &nested_loc_1, &call_list_len_0, 0),
               _fx_catch_2);
            _fx_R9Ast__id_t v_32;
            fx_str_t slit_1 = FX_MAKE_STR("len");
            FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_1, &v_32, 0), _fx_catch_2);
            FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_28, 0), _fx_catch_2);
            _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(call_list_len_0, &v_29);
            fx_str_t slit_2 = FX_MAKE_STR("");
            FX_CALL(
               _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                  &v_32, _fx_g19C_gen_code__CTypInt, &v_28, &slit_2, &v_29, 0, &nested_loc_1, &v_30, 0), _fx_catch_2);
            FX_COPY_PTR(v_30.t0, &lstlen_0);
            FX_COPY_PTR(v_30.t1, &lst_len_ccode_1);
            FX_CALL(_fx_cons_LN14C_form__cexp_t(lstlen_0, 0, true, &v_31), _fx_catch_2);
            _fx_make_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(1, v_31, lst_len_ccode_1, &v_4);

         _fx_catch_2: ;
            if (v_31) {
               _fx_free_LN14C_form__cexp_t(&v_31);
            }
            if (lst_len_ccode_1) {
               _fx_free_LN15C_form__cstmt_t(&lst_len_ccode_1);
            }
            if (lstlen_0) {
               _fx_free_N14C_form__cexp_t(&lstlen_0);
            }
            _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_30);
            _fx_free_Nt6option1N14C_form__cexp_t(&v_29);
            _fx_free_R16Ast__val_flags_t(&v_28);
            if (call_list_len_0) {
               _fx_free_N14C_form__cexp_t(&call_list_len_0);
            }
            if (v_27) {
               _fx_free_LN14C_form__cexp_t(&v_27);
            }
            goto _fx_endmatch_0;
         }
      }
   }
   if (need_make_array_0 == true) {
      if (n_exps_0 == 0) {
         if (list_exps_0 == 0) {
            fx_str_t v_33 = {0};
            fx_exn_t v_34 = {0};
            fx_str_t slit_3 = FX_MAKE_STR("array comprehension uses \'for\' with indefinite range");
            FX_CALL(_fx_M10C_gen_codeFM11for_err_msgS4iiiS(for_idx_0, nfors_0, -1, &slit_3, &v_33, 0), _fx_catch_3);
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&nested_loc_1, &v_33, &v_34, 0), _fx_catch_3);
            FX_THROW(&v_34, false, _fx_catch_3);

         _fx_catch_3: ;
            fx_free_exn(&v_34);
            FX_FREE_STR(&v_33);
            goto _fx_endmatch_0;
         }
      }
   }
   _fx_make_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(1, n_exps_0, 0, &v_4);

_fx_endmatch_0: ;
   FX_CHECK_EXN(_fx_cleanup);
   int_ ndims_i_0 = v_4.t0;
   FX_COPY_PTR(v_4.t1, &n_exps_1);
   FX_COPY_PTR(v_4.t2, &lst_len_ccode_0);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(prev_n_exps_0, n_exps_1, &n_exps_2, 0),
      _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(prev_i_exps_0, i_exps_0, &i_exps_1, 0),
      _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM2hdT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t1LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
         dst_data_0, &v_5, 0), _fx_cleanup);
   FX_COPY_PTR(v_5.t2, &dst_exp0_0);
   bool t_0;
   if (!need_make_array_0) {
      t_0 = true;
   }
   else {
      t_0 = dims_ofs_0 + ndims_i_0 < ndims_0;
   }
   if (!t_0) {
      _fx_make_T2iLN14C_form__cexp_t(0, 0, &__fold_result___0);
      _fx_LN14C_form__cexp_t lst_0 = n_exps_2;
      for (; lst_0; lst_0 = lst_0->tl) {
         _fx_T2iLN14C_form__cexp_t v_35 = {0};
         _fx_LN14C_form__cexp_t cmp_size_list_1 = 0;
         _fx_N14C_form__cexp_t v_36 = 0;
         _fx_LN14C_form__cexp_t v_37 = 0;
         _fx_N14C_form__cexp_t size_i_0 = 0;
         _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_38 = {0};
         _fx_N14C_form__cexp_t cmp_size_i_0 = 0;
         _fx_T2iLN14C_form__cexp_t v_39 = {0};
         _fx_N14C_form__cexp_t n_exp_0 = lst_0->hd;
         _fx_copy_T2iLN14C_form__cexp_t(&__fold_result___0, &v_35);
         int_ k_0 = v_35.t0;
         FX_COPY_PTR(v_35.t1, &cmp_size_list_1);
         FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(k_0, &nested_loc_1, &v_36, 0), _fx_catch_4);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(v_36, 0, true, &v_37), _fx_catch_4);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_exp0_0, v_37, false, &v_37), _fx_catch_4);
         FX_CALL(
            _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g23C_form__std_FX_ARR_SIZE, v_37, _fx_g19C_gen_code__CTypInt, &nested_loc_1, &size_i_0, 0), _fx_catch_4);
         _fx_N17C_form__cbinary_t v_40;
         _fx_M6C_formFM6COpCmpN17C_form__cbinary_t1N12Ast__cmpop_t(&_fx_g17C_gen_code__CmpEQ, &v_40);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &nested_loc_1, &v_38);
         FX_CALL(
            _fx_M6C_formFM10CExpBinaryN14C_form__cexp_t4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               &v_40, size_i_0, n_exp_0, &v_38, &cmp_size_i_0), _fx_catch_4);
         FX_CALL(_fx_cons_LN14C_form__cexp_t(cmp_size_i_0, cmp_size_list_1, false, &cmp_size_list_1), _fx_catch_4);
         _fx_make_T2iLN14C_form__cexp_t(k_0 + 1, cmp_size_list_1, &v_39);
         _fx_free_T2iLN14C_form__cexp_t(&__fold_result___0);
         _fx_copy_T2iLN14C_form__cexp_t(&v_39, &__fold_result___0);

      _fx_catch_4: ;
         _fx_free_T2iLN14C_form__cexp_t(&v_39);
         if (cmp_size_i_0) {
            _fx_free_N14C_form__cexp_t(&cmp_size_i_0);
         }
         _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_38);
         if (size_i_0) {
            _fx_free_N14C_form__cexp_t(&size_i_0);
         }
         if (v_37) {
            _fx_free_LN14C_form__cexp_t(&v_37);
         }
         if (v_36) {
            _fx_free_N14C_form__cexp_t(&v_36);
         }
         if (cmp_size_list_1) {
            _fx_free_LN14C_form__cexp_t(&cmp_size_list_1);
         }
         _fx_free_T2iLN14C_form__cexp_t(&v_35);
         FX_CHECK_EXN(_fx_cleanup);
      }
      _fx_copy_T2iLN14C_form__cexp_t(&__fold_result___0, &v_6);
      FX_COPY_PTR(v_6.t1, &cmp_size_list_0);
      if (pre_alloc_array_0) {
         FX_COPY_PTR(map_lbl_0, &lbl_1);
      }
      else {
         FX_CALL(
            _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&nested_loc_1,
               block_stack_ref_0, &lbl_1, 0), _fx_cleanup);
      }
      _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t lst_1 = dst_data_0;
      for (; lst_1; lst_1 = lst_1->tl) {
         _fx_N14C_form__ctyp_t elemtyp_0 = 0;
         _fx_N14C_form__cexp_t dst_exp_0 = 0;
         _fx_N14C_form__cexp_t dst_ptr_0 = 0;
         _fx_LN15C_form__cstmt_t then_ccode_1 = 0;
         _fx_LN15C_form__cstmt_t then_ccode_2 = 0;
         _fx_LN15C_form__cstmt_t v_41 = 0;
         _fx_N14C_form__cexp_t v_42 = 0;
         _fx_N14C_form__ctyp_t v_43 = 0;
         _fx_N14C_form__cexp_t arr_data_0 = 0;
         _fx_N14C_form__cexp_t set_dstptr_0 = 0;
         _fx_N15C_form__cstmt_t v_44 = 0;
         _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* __pat___0 = &lst_1->hd;
         FX_COPY_PTR(__pat___0->t1, &elemtyp_0);
         FX_COPY_PTR(__pat___0->t2, &dst_exp_0);
         FX_COPY_PTR(__pat___0->t3, &dst_ptr_0);
         FX_COPY_PTR(__fold_result___1, &then_ccode_1);
         FX_CALL(
            _fx_M10C_gen_codeFM18make_make_arr_callLN15C_form__cstmt_t7N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_ti(
               dst_exp_0, n_exps_2, 0, then_ccode_1, lbl_1, &nested_loc_1, km_idx_0, &then_ccode_2, 0), _fx_catch_5);
         if (is_parallel_map_0) {
            FX_COPY_PTR(then_ccode_2, &v_41);
         }
         else {
            _fx_R9Ast__id_t v_45;
            fx_str_t slit_4 = FX_MAKE_STR("data");
            FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_4, &v_45, 0), _fx_catch_5);
            FX_CALL(
               _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(dst_exp_0, &v_45,
                  _fx_g23C_form__std_CTypVoidPtr, &v_42, 0), _fx_catch_5);
            FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elemtyp_0, &v_43, 0), _fx_catch_5);
            FX_CALL(
               _fx_M6C_formFM8CExpCastN14C_form__cexp_t3N14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(v_42, v_43,
                  &nested_loc_1, &arr_data_0), _fx_catch_5);
            FX_CALL(
               _fx_M6C_formFM11make_assignN14C_form__cexp_t2N14C_form__cexp_tN14C_form__cexp_t(dst_ptr_0, arr_data_0,
                  &set_dstptr_0, 0), _fx_catch_5);
            FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(set_dstptr_0, &v_44), _fx_catch_5);
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_44, then_ccode_2, true, &v_41), _fx_catch_5);
         }
         _fx_free_LN15C_form__cstmt_t(&__fold_result___1);
         FX_COPY_PTR(v_41, &__fold_result___1);

      _fx_catch_5: ;
         if (v_44) {
            _fx_free_N15C_form__cstmt_t(&v_44);
         }
         if (set_dstptr_0) {
            _fx_free_N14C_form__cexp_t(&set_dstptr_0);
         }
         if (arr_data_0) {
            _fx_free_N14C_form__cexp_t(&arr_data_0);
         }
         if (v_43) {
            _fx_free_N14C_form__ctyp_t(&v_43);
         }
         if (v_42) {
            _fx_free_N14C_form__cexp_t(&v_42);
         }
         if (v_41) {
            _fx_free_LN15C_form__cstmt_t(&v_41);
         }
         if (then_ccode_2) {
            _fx_free_LN15C_form__cstmt_t(&then_ccode_2);
         }
         if (then_ccode_1) {
            _fx_free_LN15C_form__cstmt_t(&then_ccode_1);
         }
         if (dst_ptr_0) {
            _fx_free_N14C_form__cexp_t(&dst_ptr_0);
         }
         if (dst_exp_0) {
            _fx_free_N14C_form__cexp_t(&dst_exp_0);
         }
         if (elemtyp_0) {
            _fx_free_N14C_form__ctyp_t(&elemtyp_0);
         }
         FX_CHECK_EXN(_fx_cleanup);
      }
      FX_COPY_PTR(__fold_result___1, &then_ccode_0);
      bool t_1;
      if (for_idx_0 == 0) {
         t_1 = true;
      }
      else {
         t_1 = pre_alloc_array_0;
      }
      if (t_1) {
         FX_COPY_PTR(then_ccode_0, &alloc_array_ccode_0);
      }
      else {
         _fx_R9Ast__id_t v_46;
         fx_str_t slit_5 = FX_MAKE_STR("data");
         FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_5, &v_46, 0), _fx_cleanup);
         FX_CALL(
            _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(dst_exp0_0, &v_46,
               _fx_g23C_form__std_CTypVoidPtr, &cc_exp_0, 0), _fx_cleanup);
         _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypBool, &nested_loc_1, &v_7);
         FX_CALL(
            _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
               &_fx_g23C_gen_code__COpLogicNot, cc_exp_0, &v_7, &cc_exp_1), _fx_cleanup);
         FX_CALL(
            _fx_M10C_gen_codeFM17add_size_eq_checkLN15C_form__cstmt_t4LN14C_form__cexp_tLN15C_form__cstmt_tN14C_form__cexp_tR10Ast__loc_t(
               cmp_size_list_0, 0, lbl_1, &nested_loc_1, &else_ccode_0, 0), _fx_cleanup);
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(then_ccode_0, &nested_loc_1, &v_8,
               0), _fx_cleanup);
         FX_CALL(
            _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(else_ccode_0, &nested_loc_1, &v_9,
               0), _fx_cleanup);
         FX_CALL(
            _fx_M10C_gen_codeFM7make_ifN15C_form__cstmt_t4N14C_form__cexp_tN15C_form__cstmt_tN15C_form__cstmt_tR10Ast__loc_t(
               cc_exp_1, v_8, v_9, &nested_loc_1, &check_or_create_0, 0), _fx_cleanup);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(check_or_create_0, 0, true, &alloc_array_ccode_0), _fx_cleanup);
      }
   }
   if (pre_alloc_array_0) {
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(pre_map_ccode_delta_0,
            pre_map_ccode_0, &v_11, 0), _fx_cleanup);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(alloc_array_ccode_0, v_11, &v_12,
            0), _fx_cleanup);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(lst_len_ccode_0, init_ccode_0,
            &v_13, 0), _fx_cleanup);
      _fx_make_Ta2LN15C_form__cstmt_t(v_12, v_13, &v_10);
   }
   else {
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(pre_map_ccode_delta_0,
            init_ccode_0, &v_14, 0), _fx_cleanup);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(lst_len_ccode_0, v_14, &v_15, 0),
         _fx_cleanup);
      FX_CALL(
         _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(alloc_array_ccode_0, v_15, &v_16,
            0), _fx_cleanup);
      _fx_make_Ta2LN15C_form__cstmt_t(pre_map_ccode_0, v_16, &v_10);
   }
   FX_COPY_PTR(v_10.t0, &pre_map_ccode_1);
   FX_COPY_PTR(v_10.t1, &init_ccode_1);
   _fx_R16Ast__for_flags_t v_47;
   FX_CALL(_fx_M3AstFM17default_for_flagsRM11for_flags_t0(&v_47, 0), _fx_cleanup);
   bool t_2;
   if (is_parallel_map_0) {
      t_2 = for_idx_0 <= 0;
   }
   else {
      t_2 = false;
   }
   _fx_R16Ast__for_flags_t for_flags_0 = { t_2, v_47.for_flag_make, v_47.for_flag_unzip, v_47.for_flag_fold, for_idx_0 > 0 };
   FX_CALL(
      _fx_M10C_gen_codeFM17new_for_block_ctxv7iR16Ast__for_flags_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_trLrRM11block_ctx_ti(
         ndims_0, &for_flags_0, nested_status_0, par_status_0, kloc_0, block_stack_ref_0, km_idx_0, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM19decl_for_body_elemsLN15C_form__cstmt_t4LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_trLrRM11block_ctx_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t(
         body_elems_0, 0, block_stack_ref_0, i2e_ref_0, &body_ccode_0, 0), _fx_cleanup);
   if (nested_e_idoml_0 != 0) {
      if (nested_e_idoml_0->tl == 0) {
         _fx_T3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t* v_48 = &nested_e_idoml_0->hd;
         if (v_48->t2 == 0) {
            if (v_48->t1 == 0) {
               _fx_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t
                  v_49 = {0};
               fx_str_t v_50 = {0};
               fx_str_t v_51 = {0};
               fx_str_t v_52 = {0};
               fx_exn_t v_53 = {0};
               _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t
                  __fold_result___3 = {0};
               _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t
                  v_54 = {0};
               _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_2 = 0;
               _fx_LN15C_form__cstmt_t decl_dstptr_ccode_all_0 = 0;
               _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_55 = 0;
               _fx_LN15C_form__cstmt_t v_56 = 0;
               _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_57 = 0;
               _fx_LN15C_form__cstmt_t v_58 = 0;
               _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_3 = 0;
               _fx_LN15C_form__cstmt_t pre_body_ccode_2 = 0;
               _fx_LN15C_form__cstmt_t body_ccode_2 = 0;
               _fx_rNt6option1N14C_form__cexp_t v_59 = 0;
               _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_60 = {0};
               _fx_N14C_form__cexp_t result_0 = 0;
               _fx_LN15C_form__cstmt_t body_ccode_3 = 0;
               _fx_LN15C_form__cstmt_t __fold_result___4 = 0;
               _fx_LN15C_form__cstmt_t body_ccode_4 = 0;
               _fx_Ta2LN15C_form__cstmt_t v_61 = {0};
               _fx_N14K_form__kexp_t body_0 = v_48->t0;
               _fx_R10Ast__loc_t body_loc_0;
               FX_CALL(_fx_M6K_formFM12get_kexp_locR10Ast__loc_t1N14K_form__kexp_t(body_0, &body_loc_0, 0), _fx_catch_14);
               if (!is_parallel_map_0) {
                  _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                     true, dst_data_0, pre_body_ccode_0, body_ccode_0, &v_49);
               }
               else {
                  int_ n_i_exps_0;
                  FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(i_exps_1, &n_i_exps_0, 0), _fx_catch_14);
                  int_ v_62;
                  FX_CALL(_fx_M10C_gen_codeFM8length1_i1LN14C_form__cexp_t(n_exps_2, &v_62, 0), _fx_catch_14);
                  bool t_3;
                  if (n_i_exps_0 == v_62) {
                     t_3 = n_i_exps_0 == ndims_0;
                  }
                  else {
                     t_3 = false;
                  }
                  if (!t_3) {
                     FX_CALL(_fx_F6stringS1i(n_i_exps_0, &v_50, 0), _fx_catch_14);
                     FX_CALL(_fx_F6stringS1i(ndims_0, &v_51, 0), _fx_catch_14);
                     fx_str_t slit_6 =
                        FX_MAKE_STR(
                           "cgen: internal error when compiling parallel for: incorrect number of iteration indices (=");
                     fx_str_t slit_7 = FX_MAKE_STR(").There should be as many as the output array dimensionality (=");
                     fx_str_t slit_8 = FX_MAKE_STR(")");
                     {
                        const fx_str_t strs_0[] = { slit_6, v_50, slit_7, v_51, slit_8 };
                        FX_CALL(fx_strjoin(0, 0, 0, strs_0, 5, &v_52), _fx_catch_14);
                     }
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&body_loc_0, &v_52, &v_53, 0), _fx_catch_14);
                     FX_THROW(&v_53, false, _fx_catch_14);
                  }
                  _fx_make_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                     0, 0, &__fold_result___3);
                  _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t lst_2 =
                     dst_data_0;
                  for (; lst_2; lst_2 = lst_2->tl) {
                     _fx_N14C_form__ctyp_t coll_ctyp_0 = 0;
                     _fx_N14C_form__ctyp_t elemtyp_1 = 0;
                     _fx_N14C_form__cexp_t dst_exp_1 = 0;
                     _fx_N14C_form__cexp_t iter_0 = 0;
                     _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t
                        v_63 = {0};
                     _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t dst_data_4 =
                        0;
                     _fx_LN15C_form__cstmt_t decl_dstptr_ccode_all_1 = 0;
                     _fx_N14C_form__ctyp_t elemtyp_ptr_0 = 0;
                     _fx_LN14C_form__cexp_t dst_idxs_0 = 0;
                     _fx_N14C_form__cexp_t v_64 = 0;
                     _fx_LN14C_form__cexp_t v_65 = 0;
                     _fx_LN14C_form__cexp_t v_66 = 0;
                     _fx_LN14C_form__cexp_t v_67 = 0;
                     _fx_N14C_form__cexp_t v_68 = 0;
                     _fx_LN14C_form__cexp_t v_69 = 0;
                     _fx_N14C_form__cexp_t get_arr_slice_0 = 0;
                     _fx_R16Ast__val_flags_t v_70 = {0};
                     _fx_Nt6option1N14C_form__cexp_t v_71 = {0};
                     _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_72 = {0};
                     _fx_N14C_form__cexp_t dst_ptr_1 = 0;
                     _fx_LN15C_form__cstmt_t decl_dstptr_ccode_0 = 0;
                     _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t v_73 = {0};
                     _fx_LN15C_form__cstmt_t v_74 = 0;
                     _fx_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t
                        v_75 = {0};
                     _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* __pat___1 =
                        &lst_2->hd;
                     FX_COPY_PTR(__pat___1->t0, &coll_ctyp_0);
                     FX_COPY_PTR(__pat___1->t1, &elemtyp_1);
                     FX_COPY_PTR(__pat___1->t2, &dst_exp_1);
                     FX_COPY_PTR(__pat___1->t4, &iter_0);
                     _fx_copy_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                        &__fold_result___3, &v_63);
                     FX_COPY_PTR(v_63.t0, &dst_data_4);
                     FX_COPY_PTR(v_63.t1, &decl_dstptr_ccode_all_1);
                     FX_CALL(_fx_M6C_formFM8make_ptrN14C_form__ctyp_t1N14C_form__ctyp_t(elemtyp_1, &elemtyp_ptr_0, 0),
                        _fx_catch_6);
                     if (ndims_0 == 1) {
                        FX_COPY_PTR(i_exps_1, &dst_idxs_0);
                     }
                     else {
                        FX_CALL(_fx_M6C_formFM12make_int_expN14C_form__cexp_t2iR10Ast__loc_t(0, &body_loc_0, &v_64, 0),
                           _fx_catch_6);
                        FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(i_exps_1, &v_65, 0), _fx_catch_6);
                        FX_CALL(_fx_M10C_gen_codeFM2tlLN14C_form__cexp_t1LN14C_form__cexp_t(v_65, &v_66, 0), _fx_catch_6);
                        FX_CALL(_fx_cons_LN14C_form__cexp_t(v_64, v_66, true, &v_67), _fx_catch_6);
                        FX_CALL(_fx_M10C_gen_codeFM3revLN14C_form__cexp_t1LN14C_form__cexp_t(v_67, &dst_idxs_0, 0),
                           _fx_catch_6);
                     }
                     _fx_R9Ast__id_t v_76;
                     FX_CALL(
                        _fx_M10C_gen_codeFM3nthR9Ast__id_t2LR9Ast__id_ti(_fx_g21C_form__std_FX_PTR_xD, ndims_0 - 1, &v_76, 0),
                        _fx_catch_6);
                     FX_CALL(
                        _fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elemtyp_1, &body_loc_0, &v_68),
                        _fx_catch_6);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_exp_1, dst_idxs_0, true, &v_69), _fx_catch_6);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_68, v_69, false, &v_69), _fx_catch_6);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &v_76, v_69, elemtyp_ptr_0, &body_loc_0, &get_arr_slice_0, 0), _fx_catch_6);
                     _fx_R9Ast__id_t v_77;
                     fx_str_t slit_9 = FX_MAKE_STR("dstptr");
                     FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_9, &v_77, 0), _fx_catch_6);
                     FX_CALL(_fx_M3AstFM21default_tempvar_flagsRM11val_flags_t0(&v_70, 0), _fx_catch_6);
                     _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(get_arr_slice_0, &v_71);
                     fx_str_t slit_10 = FX_MAKE_STR("");
                     FX_CALL(
                        _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                           &v_77, elemtyp_ptr_0, &v_70, &slit_10, &v_71, 0, &body_loc_0, &v_72, 0), _fx_catch_6);
                     FX_COPY_PTR(v_72.t0, &dst_ptr_1);
                     FX_COPY_PTR(v_72.t1, &decl_dstptr_ccode_0);
                     _fx_make_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                        coll_ctyp_0, elemtyp_1, dst_exp_1, dst_ptr_1, iter_0, &v_73);
                     FX_CALL(
                        _fx_cons_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_73,
                           dst_data_4, false, &dst_data_4), _fx_catch_6);
                     FX_CALL(
                        _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(
                           decl_dstptr_ccode_0, decl_dstptr_ccode_all_1, &v_74, 0), _fx_catch_6);
                     _fx_make_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                        dst_data_4, v_74, &v_75);
                     _fx_free_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                        &__fold_result___3);
                     _fx_copy_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                        &v_75, &__fold_result___3);

                  _fx_catch_6: ;
                     _fx_free_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                        &v_75);
                     if (v_74) {
                        _fx_free_LN15C_form__cstmt_t(&v_74);
                     }
                     _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_73);
                     if (decl_dstptr_ccode_0) {
                        _fx_free_LN15C_form__cstmt_t(&decl_dstptr_ccode_0);
                     }
                     if (dst_ptr_1) {
                        _fx_free_N14C_form__cexp_t(&dst_ptr_1);
                     }
                     _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_72);
                     _fx_free_Nt6option1N14C_form__cexp_t(&v_71);
                     _fx_free_R16Ast__val_flags_t(&v_70);
                     if (get_arr_slice_0) {
                        _fx_free_N14C_form__cexp_t(&get_arr_slice_0);
                     }
                     if (v_69) {
                        _fx_free_LN14C_form__cexp_t(&v_69);
                     }
                     if (v_68) {
                        _fx_free_N14C_form__cexp_t(&v_68);
                     }
                     if (v_67) {
                        _fx_free_LN14C_form__cexp_t(&v_67);
                     }
                     if (v_66) {
                        _fx_free_LN14C_form__cexp_t(&v_66);
                     }
                     if (v_65) {
                        _fx_free_LN14C_form__cexp_t(&v_65);
                     }
                     if (v_64) {
                        _fx_free_N14C_form__cexp_t(&v_64);
                     }
                     if (dst_idxs_0) {
                        _fx_free_LN14C_form__cexp_t(&dst_idxs_0);
                     }
                     if (elemtyp_ptr_0) {
                        _fx_free_N14C_form__ctyp_t(&elemtyp_ptr_0);
                     }
                     if (decl_dstptr_ccode_all_1) {
                        _fx_free_LN15C_form__cstmt_t(&decl_dstptr_ccode_all_1);
                     }
                     if (dst_data_4) {
                        _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                           &dst_data_4);
                     }
                     _fx_free_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                        &v_63);
                     if (iter_0) {
                        _fx_free_N14C_form__cexp_t(&iter_0);
                     }
                     if (dst_exp_1) {
                        _fx_free_N14C_form__cexp_t(&dst_exp_1);
                     }
                     if (elemtyp_1) {
                        _fx_free_N14C_form__ctyp_t(&elemtyp_1);
                     }
                     if (coll_ctyp_0) {
                        _fx_free_N14C_form__ctyp_t(&coll_ctyp_0);
                     }
                     FX_CHECK_EXN(_fx_catch_14);
                  }
                  _fx_copy_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                     &__fold_result___3, &v_54);
                  FX_COPY_PTR(v_54.t0, &dst_data_2);
                  FX_COPY_PTR(v_54.t1, &decl_dstptr_ccode_all_0);
                  if (ndims_0 == 1) {
                     FX_CALL(
                        _fx_M10C_gen_codeFM3revLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t1LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                           dst_data_2, &v_55, 0), _fx_catch_14);
                     FX_CALL(
                        _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(
                           decl_dstptr_ccode_all_0, body_ccode_0, &v_56, 0), _fx_catch_14);
                     _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                        false, v_55, pre_body_ccode_0, v_56, &v_49);
                  }
                  else {
                     FX_CALL(
                        _fx_M10C_gen_codeFM3revLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t1LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                           dst_data_2, &v_57, 0), _fx_catch_14);
                     FX_CALL(
                        _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(
                           decl_dstptr_ccode_all_0, pre_body_ccode_0, &v_58, 0), _fx_catch_14);
                     _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                        true, v_57, v_58, body_ccode_0, &v_49);
                  }
               }
               bool add_incr_dstptr_0 = v_49.t0;
               FX_COPY_PTR(v_49.t1, &dst_data_3);
               FX_COPY_PTR(v_49.t2, &pre_body_ccode_2);
               FX_COPY_PTR(v_49.t3, &body_ccode_2);
               FX_CALL(_fx_make_rNt6option1N14C_form__cexp_t(&_fx_g18C_gen_code__None2_, &v_59), _fx_catch_14);
               FX_CALL(
                  kexp2cexp_0.fp(body_0, v_59, body_ccode_2, block_stack_ref_0, defined_syms_ref_0, for_letters_0,
                     func_dstexp_r_ref_0, fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, km_idx_0, mod_sc_0,
                     module_cleanup_ref_0, return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, &v_60, kexp2cexp_0.fcv),
                  _fx_catch_14);
               FX_COPY_PTR(v_60.t0, &result_0);
               FX_COPY_PTR(v_60.t1, &body_ccode_3);
               FX_COPY_PTR(body_ccode_3, &__fold_result___4);
               int_ j_0 = 0;
               _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t lst_3 = dst_data_3;
               for (; lst_3; lst_3 = lst_3->tl, j_0 += 1) {
                  _fx_N14C_form__ctyp_t coll_ctyp_1 = 0;
                  _fx_N14C_form__ctyp_t elemtyp_2 = 0;
                  _fx_N14C_form__cexp_t dst_exp_2 = 0;
                  _fx_N14C_form__cexp_t dst_ptr_2 = 0;
                  _fx_N14C_form__cexp_t iter_1 = 0;
                  _fx_LN15C_form__cstmt_t body_ccode_5 = 0;
                  _fx_N14C_form__cexp_t result_j_0 = 0;
                  _fx_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti v_78 = {0};
                  _fx_N14C_form__cexp_t result_1 = 0;
                  _fx_LT2R9Ast__id_tN14C_form__ctyp_t relems_0 = 0;
                  fx_str_t v_79 = {0};
                  fx_str_t v_80 = {0};
                  fx_str_t v_81 = {0};
                  fx_exn_t v_82 = {0};
                  _fx_T2R9Ast__id_tN14C_form__ctyp_t v_83 = {0};
                  _fx_LN15C_form__cstmt_t v_84 = 0;
                  _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* __pat___2 =
                     &lst_3->hd;
                  FX_COPY_PTR(__pat___2->t0, &coll_ctyp_1);
                  FX_COPY_PTR(__pat___2->t1, &elemtyp_2);
                  FX_COPY_PTR(__pat___2->t2, &dst_exp_2);
                  FX_COPY_PTR(__pat___2->t3, &dst_ptr_2);
                  FX_COPY_PTR(__pat___2->t4, &iter_1);
                  FX_COPY_PTR(__fold_result___4, &body_ccode_5);
                  if (!unzip_mode_0) {
                     FX_COPY_PTR(result_0, &result_j_0);
                  }
                  else {
                     FX_CALL(
                        _fx_M10C_gen_codeFM10get_structT4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti1N14C_form__cexp_t(
                           result_0, &v_78, 0), _fx_catch_13);
                     FX_COPY_PTR(v_78.t1, &result_1);
                     FX_COPY_PTR(v_78.t2, &relems_0);
                     int_ ofs_0 = v_78.t3;
                     int_ nelems_0;
                     FX_CALL(_fx_M10C_gen_codeFM8length1_i1LT2R9Ast__id_tN14C_form__ctyp_t(relems_0, &nelems_0, 0),
                        _fx_catch_13);
                     bool t_4;
                     if (j_0 < 0) {
                        t_4 = true;
                     }
                     else {
                        t_4 = j_0 + ofs_0 >= nelems_0;
                     }
                     if (t_4) {
                        FX_CALL(_fx_F6stringS1i(j_0, &v_79, 0), _fx_catch_13);
                        FX_CALL(_fx_F6stringS1i(nelems_0, &v_80, 0), _fx_catch_13);
                        fx_str_t slit_11 = FX_MAKE_STR("cgen: the tuple/record element index ");
                        fx_str_t slit_12 = FX_MAKE_STR(" is out of range [:: 0, ");
                        fx_str_t slit_13 = FX_MAKE_STR("]");
                        {
                           const fx_str_t strs_1[] = { slit_11, v_79, slit_12, v_80, slit_13 };
                           FX_CALL(fx_strjoin(0, 0, 0, strs_1, 5, &v_81), _fx_catch_13);
                        }
                        FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&body_loc_0, &v_81, &v_82, 0), _fx_catch_13);
                        FX_THROW(&v_82, false, _fx_catch_13);
                     }
                     FX_CALL(
                        _fx_M10C_gen_codeFM3nthT2R9Ast__id_tN14C_form__ctyp_t2LT2R9Ast__id_tN14C_form__ctyp_ti(relems_0,
                           j_0 + ofs_0, &v_83, 0), _fx_catch_13);
                     _fx_R9Ast__id_t j_id_0 = v_83.t0;
                     FX_CALL(
                        _fx_M6C_formFM8cexp_memN14C_form__cexp_t3N14C_form__cexp_tR9Ast__id_tN14C_form__ctyp_t(result_1,
                           &j_id_0, elemtyp_2, &result_j_0, 0), _fx_catch_13);
                  }
                  int tag_0 = for_flag_make_0->tag;
                  if (tag_0 == 2) {
                     _fx_N14C_form__cexp_t v_85 = 0;
                     FX_CALL(_fx_M6C_formFM10cexp_derefN14C_form__cexp_t1N14C_form__cexp_t(dst_ptr_2, &v_85, 0), _fx_catch_7);
                     FX_CALL(
                        _fx_M11C_gen_typesFM13gen_copy_codeLN15C_form__cstmt_t5N14C_form__cexp_tN14C_form__cexp_tN14C_form__ctyp_tLN15C_form__cstmt_tR10Ast__loc_t(
                           result_j_0, v_85, elemtyp_2, body_ccode_5, &body_loc_0, &v_84, 0), _fx_catch_7);

                  _fx_catch_7: ;
                     if (v_85) {
                        _fx_free_N14C_form__cexp_t(&v_85);
                     }
                  }
                  else if (tag_0 == 4) {
                     _fx_T2BNt6option1N14C_form__cexp_t v_86 = {0};
                     _fx_N14C_form__cexp_t lbl_2 = 0;
                     _fx_N14C_form__cexp_t v_87 = 0;
                     _fx_LN14C_form__cexp_t v_88 = 0;
                     _fx_N14C_form__cexp_t write_call_0 = 0;
                     _fx_N15C_form__cstmt_t v_89 = 0;
                     FX_CALL(
                        _fx_M11C_gen_typesFM10get_copy_fT2BNt6option1N14C_form__cexp_t4N14C_form__ctyp_tBBR10Ast__loc_t(
                           elemtyp_2, true, false, &body_loc_0, &v_86, 0), _fx_catch_10);
                     _fx_R9Ast__id_t write_f_0;
                     if (v_86.t1.tag == 2) {
                        fx_str_t slit_14 = FX_MAKE_STR("FX_RRB_WRITE");
                        FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_14, &write_f_0, 0), _fx_catch_8);

                     _fx_catch_8: ;
                     }
                     else {
                        fx_str_t slit_15 = FX_MAKE_STR("FX_RRB_WRITE_FAST");
                        FX_CALL(_fx_M3AstFM6get_idRM4id_t1S(&slit_15, &write_f_0, 0), _fx_catch_9);

                     _fx_catch_9: ;
                     }
                     FX_CHECK_EXN(_fx_catch_10);
                     FX_CALL(
                        _fx_M10C_gen_codeFM16curr_block_labelN14C_form__cexp_t2R10Ast__loc_trLrRM11block_ctx_t(&body_loc_0,
                           block_stack_ref_0, &lbl_2, 0), _fx_catch_10);
                     FX_CALL(
                        _fx_M6C_formFM7CExpTypN14C_form__cexp_t2N14C_form__ctyp_tR10Ast__loc_t(elemtyp_2, &body_loc_0, &v_87),
                        _fx_catch_10);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(lbl_2, 0, true, &v_88), _fx_catch_10);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(result_j_0, v_88, false, &v_88), _fx_catch_10);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_ptr_2, v_88, false, &v_88), _fx_catch_10);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(iter_1, v_88, false, &v_88), _fx_catch_10);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(v_87, v_88, false, &v_88), _fx_catch_10);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &write_f_0, v_88, _fx_g20C_gen_code__CTypVoid, &body_loc_0, &write_call_0, 0), _fx_catch_10);
                     FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(write_call_0, &v_89), _fx_catch_10);
                     FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_89, body_ccode_5, true, &v_84), _fx_catch_10);

                  _fx_catch_10: ;
                     if (v_89) {
                        _fx_free_N15C_form__cstmt_t(&v_89);
                     }
                     if (write_call_0) {
                        _fx_free_N14C_form__cexp_t(&write_call_0);
                     }
                     if (v_88) {
                        _fx_free_LN14C_form__cexp_t(&v_88);
                     }
                     if (v_87) {
                        _fx_free_N14C_form__cexp_t(&v_87);
                     }
                     if (lbl_2) {
                        _fx_free_N14C_form__cexp_t(&lbl_2);
                     }
                     _fx_free_T2BNt6option1N14C_form__cexp_t(&v_86);
                  }
                  else if (tag_0 == 3) {
                     _fx_R16Ast__val_flags_t v_90 = {0};
                     _fx_N14C_form__cexp_t v_91 = 0;
                     _fx_Nt6option1N14C_form__cexp_t v_92 = {0};
                     _fx_T2N14C_form__cexp_tLN15C_form__cstmt_t v_93 = {0};
                     _fx_N14C_form__cexp_t node_exp_0 = 0;
                     _fx_LN15C_form__cstmt_t body_ccode_6 = 0;
                     _fx_N14C_form__cexp_t v_94 = 0;
                     _fx_LN15C_form__cstmt_t body_ccode_7 = 0;
                     _fx_LN14C_form__cexp_t v_95 = 0;
                     _fx_N14C_form__cexp_t append_call_0 = 0;
                     _fx_N15C_form__cstmt_t v_96 = 0;
                     _fx_R9Ast__id_t v_97;
                     fx_str_t slit_16 = FX_MAKE_STR("node");
                     FX_CALL(_fx_M6C_formFM7gen_idcR9Ast__id_t2iS(km_idx_0, &slit_16, &v_97, 0), _fx_catch_11);
                     FX_CALL(_fx_M3AstFM21default_tempval_flagsRM11val_flags_t0(&v_90, 0), _fx_catch_11);
                     FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&body_loc_0, &v_91, 0), _fx_catch_11);
                     _fx_M10C_gen_codeFM4SomeNt6option1N14C_form__cexp_t1N14C_form__cexp_t(v_91, &v_92);
                     fx_str_t slit_17 = FX_MAKE_STR("");
                     FX_CALL(
                        _fx_M6C_formFM14create_cdefvalT2N14C_form__cexp_tLN15C_form__cstmt_t7R9Ast__id_tN14C_form__ctyp_tR16Ast__val_flags_tSNt6option1N14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_t(
                           &v_97, coll_ctyp_1, &v_90, &slit_17, &v_92, body_ccode_5, &body_loc_0, &v_93, 0), _fx_catch_11);
                     FX_COPY_PTR(v_93.t0, &node_exp_0);
                     FX_COPY_PTR(v_93.t1, &body_ccode_6);
                     FX_CALL(_fx_M6C_formFM12make_nullptrN14C_form__cexp_t1R10Ast__loc_t(&body_loc_0, &v_94, 0), _fx_catch_11);
                     FX_CALL(
                        _fx_M10C_gen_codeFM14make_cons_callLN15C_form__cstmt_t7N14C_form__cexp_tN14C_form__cexp_tBN14C_form__cexp_tLN15C_form__cstmt_tR10Ast__loc_trLrRM11block_ctx_t(
                           result_j_0, v_94, false, node_exp_0, body_ccode_6, &body_loc_0, block_stack_ref_0, &body_ccode_7, 0),
                        _fx_catch_11);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(node_exp_0, 0, true, &v_95), _fx_catch_11);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(iter_1, v_95, false, &v_95), _fx_catch_11);
                     FX_CALL(_fx_cons_LN14C_form__cexp_t(dst_exp_2, v_95, false, &v_95), _fx_catch_11);
                     FX_CALL(
                        _fx_M6C_formFM9make_callN14C_form__cexp_t4R9Ast__id_tLN14C_form__cexp_tN14C_form__ctyp_tR10Ast__loc_t(
                           &_fx_g26C_form__std_FX_LIST_APPEND, v_95, _fx_g20C_gen_code__CTypVoid, &body_loc_0, &append_call_0,
                           0), _fx_catch_11);
                     FX_CALL(_fx_M6C_formFM4CExpN15C_form__cstmt_t1N14C_form__cexp_t(append_call_0, &v_96), _fx_catch_11);
                     FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_96, body_ccode_7, true, &v_84), _fx_catch_11);

                  _fx_catch_11: ;
                     if (v_96) {
                        _fx_free_N15C_form__cstmt_t(&v_96);
                     }
                     if (append_call_0) {
                        _fx_free_N14C_form__cexp_t(&append_call_0);
                     }
                     if (v_95) {
                        _fx_free_LN14C_form__cexp_t(&v_95);
                     }
                     if (body_ccode_7) {
                        _fx_free_LN15C_form__cstmt_t(&body_ccode_7);
                     }
                     if (v_94) {
                        _fx_free_N14C_form__cexp_t(&v_94);
                     }
                     if (body_ccode_6) {
                        _fx_free_LN15C_form__cstmt_t(&body_ccode_6);
                     }
                     if (node_exp_0) {
                        _fx_free_N14C_form__cexp_t(&node_exp_0);
                     }
                     _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_93);
                     _fx_free_Nt6option1N14C_form__cexp_t(&v_92);
                     if (v_91) {
                        _fx_free_N14C_form__cexp_t(&v_91);
                     }
                     _fx_free_R16Ast__val_flags_t(&v_90);
                  }
                  else {
                     fx_exn_t v_98 = {0};
                     fx_str_t slit_18 =
                        FX_MAKE_STR("unsupported kind of comprehension (only arrays, vectors and lists are supported)");
                     FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&body_loc_0, &slit_18, &v_98, 0), _fx_catch_12);
                     FX_THROW(&v_98, false, _fx_catch_12);

                  _fx_catch_12: ;
                     fx_free_exn(&v_98);
                  }
                  FX_CHECK_EXN(_fx_catch_13);
                  _fx_free_LN15C_form__cstmt_t(&__fold_result___4);
                  FX_COPY_PTR(v_84, &__fold_result___4);

               _fx_catch_13: ;
                  if (v_84) {
                     _fx_free_LN15C_form__cstmt_t(&v_84);
                  }
                  _fx_free_T2R9Ast__id_tN14C_form__ctyp_t(&v_83);
                  fx_free_exn(&v_82);
                  FX_FREE_STR(&v_81);
                  FX_FREE_STR(&v_80);
                  FX_FREE_STR(&v_79);
                  if (relems_0) {
                     _fx_free_LT2R9Ast__id_tN14C_form__ctyp_t(&relems_0);
                  }
                  if (result_1) {
                     _fx_free_N14C_form__cexp_t(&result_1);
                  }
                  _fx_free_T4R9Ast__id_tN14C_form__cexp_tLT2R9Ast__id_tN14C_form__ctyp_ti(&v_78);
                  if (result_j_0) {
                     _fx_free_N14C_form__cexp_t(&result_j_0);
                  }
                  if (body_ccode_5) {
                     _fx_free_LN15C_form__cstmt_t(&body_ccode_5);
                  }
                  if (iter_1) {
                     _fx_free_N14C_form__cexp_t(&iter_1);
                  }
                  if (dst_ptr_2) {
                     _fx_free_N14C_form__cexp_t(&dst_ptr_2);
                  }
                  if (dst_exp_2) {
                     _fx_free_N14C_form__cexp_t(&dst_exp_2);
                  }
                  if (elemtyp_2) {
                     _fx_free_N14C_form__ctyp_t(&elemtyp_2);
                  }
                  if (coll_ctyp_1) {
                     _fx_free_N14C_form__ctyp_t(&coll_ctyp_1);
                  }
                  FX_CHECK_EXN(_fx_catch_14);
               }
               FX_COPY_PTR(__fold_result___4, &body_ccode_4);
               bool t_5;
               if (add_incr_dstptr_0) {
                  t_5 = need_make_array_0;
               }
               else {
                  t_5 = false;
               }
               _fx_make_Ta2LN15C_form__cstmt_t(pre_map_ccode_1, body_ccode_4, &v_61);
               _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t(
                  t_5, dst_data_3, pre_body_ccode_2, &v_61, &v_17);

            _fx_catch_14: ;
               _fx_free_Ta2LN15C_form__cstmt_t(&v_61);
               if (body_ccode_4) {
                  _fx_free_LN15C_form__cstmt_t(&body_ccode_4);
               }
               if (__fold_result___4) {
                  _fx_free_LN15C_form__cstmt_t(&__fold_result___4);
               }
               if (body_ccode_3) {
                  _fx_free_LN15C_form__cstmt_t(&body_ccode_3);
               }
               if (result_0) {
                  _fx_free_N14C_form__cexp_t(&result_0);
               }
               _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_60);
               if (v_59) {
                  _fx_free_rNt6option1N14C_form__cexp_t(&v_59);
               }
               if (body_ccode_2) {
                  _fx_free_LN15C_form__cstmt_t(&body_ccode_2);
               }
               if (pre_body_ccode_2) {
                  _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_2);
               }
               if (dst_data_3) {
                  _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                     &dst_data_3);
               }
               if (v_58) {
                  _fx_free_LN15C_form__cstmt_t(&v_58);
               }
               if (v_57) {
                  _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_57);
               }
               if (v_56) {
                  _fx_free_LN15C_form__cstmt_t(&v_56);
               }
               if (v_55) {
                  _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_55);
               }
               if (decl_dstptr_ccode_all_0) {
                  _fx_free_LN15C_form__cstmt_t(&decl_dstptr_ccode_all_0);
               }
               if (dst_data_2) {
                  _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(
                     &dst_data_2);
               }
               _fx_free_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                  &v_54);
               _fx_free_T2LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_t(
                  &__fold_result___3);
               fx_free_exn(&v_53);
               FX_FREE_STR(&v_52);
               FX_FREE_STR(&v_51);
               FX_FREE_STR(&v_50);
               _fx_free_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
                  &v_49);
               goto _fx_endmatch_1;
            }
         }
      }
   }
   _fx_Ta2LN15C_form__cstmt_t v_99 = {0};
   FX_CALL(
      _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB(
         pre_map_ccode_1, for_idx_0 + 1, nested_e_idoml_0, i_exps_1, n_exps_2, block_stack_ref_0, decl_nested_status_0,
         defined_syms_ref_0, dst_data_0, end_for_loc_0, for_flag_make_0, for_letters_0, for_loc_0, func_dstexp_r_ref_0,
         fwd_fdecls_ref_0, fx_status__0, glob_data_ccode_ref_0, i2e_ref_0, is_parallel_map_0, kloc_0, km_idx_0, map_lbl_0,
         mod_sc_0, module_cleanup_ref_0, ndims_0, need_make_array_0, nested_status_0, nfors_0, par_status_0, pre_alloc_array_0,
         return_used_ref_0, top_inline_ccode_ref_0, u1vals_0, unzip_mode_0, &v_99, fx_fv), _fx_catch_15);
   _fx_make_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t(
      false, dst_data_0, pre_body_ccode_0, &v_99, &v_17);

_fx_catch_15: ;
   _fx_free_Ta2LN15C_form__cstmt_t(&v_99);

_fx_endmatch_1: ;
   FX_CHECK_EXN(_fx_cleanup);
   bool add_incr_dstptr_1 = v_17.t0;
   FX_COPY_PTR(v_17.t1, &dst_data_1);
   FX_COPY_PTR(v_17.t2, &pre_body_ccode_1);
   _fx_Ta2LN15C_form__cstmt_t* v_100 = &v_17.t3;
   FX_COPY_PTR(v_100->t0, &pre_map_ccode_2);
   FX_COPY_PTR(v_100->t1, &body_ccode_1);
   FX_CALL(
      _fx_M10C_gen_codeFM18finalize_loop_bodyT2R9Ast__id_tN15C_form__cstmt_t4LN15C_form__cstmt_tBR10Ast__loc_trLrRM11block_ctx_t(
         body_ccode_1, !need_make_array_0, kloc_0, block_stack_ref_0, &v_18, 0), _fx_cleanup);
   _fx_R9Ast__id_t br_label_0 = v_18.t0;
   FX_COPY_PTR(v_18.t1, &body_stmt_0);
   int_ nfor_headers_0;
   FX_CALL(
      _fx_M10C_gen_codeFM8length1_i1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         for_headers_0, &nfor_headers_0, 0), _fx_cleanup);
   FX_CALL(_fx_M6C_formFM10stmt2ccodeLN15C_form__cstmt_t1N15C_form__cstmt_t(body_stmt_0, &v_19, 0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM3revLN15C_form__cstmt_t1LN15C_form__cstmt_t(v_19, &__fold_result___2, 0), _fx_cleanup);
   FX_CALL(
      _fx_M10C_gen_codeFM3revLT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t1LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(
         for_headers_0, &v_20, 0), _fx_cleanup);
   int_ k_1 = 0;
   _fx_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t lst_4 = v_20;
   for (; lst_4; lst_4 = lst_4->tl, k_1 += 1) {
      _fx_Nt6option1N14C_form__ctyp_t t_opt_0 = {0};
      _fx_LN14C_form__cexp_t for_inits_0 = 0;
      _fx_Nt6option1N14C_form__cexp_t for_check_opt_0 = {0};
      _fx_LN14C_form__cexp_t for_incrs_0 = 0;
      _fx_LN15C_form__cstmt_t for_ccode_1 = 0;
      _fx_LN14C_form__cexp_t for_incrs_1 = 0;
      _fx_LN14C_form__cexp_t v_101 = 0;
      _fx_LN15C_form__cstmt_t for_body_ccode_0 = 0;
      _fx_Ta2Nt6option1N14C_form__ctyp_t v_102 = {0};
      _fx_Nt6option1N14C_form__ctyp_t t_opt_1 = {0};
      _fx_Nt6option1N14C_form__ctyp_t init_t_opt_0 = {0};
      _fx_LN15C_form__cstmt_t for_ccode_2 = 0;
      _fx_N15C_form__cstmt_t v_103 = 0;
      _fx_N15C_form__cstmt_t v_104 = 0;
      _fx_LN15C_form__cstmt_t for_ccode_3 = 0;
      _fx_LN15C_form__cstmt_t for_ccode_4 = 0;
      _fx_N15C_form__cstmt_t v_105 = 0;
      _fx_LN15C_form__cstmt_t v_106 = 0;
      _fx_LN15C_form__cstmt_t for_ccode_5 = 0;
      _fx_T4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t* __pat___3 = &lst_4->hd;
      _fx_copy_Nt6option1N14C_form__ctyp_t(&__pat___3->t0, &t_opt_0);
      FX_COPY_PTR(__pat___3->t1, &for_inits_0);
      _fx_copy_Nt6option1N14C_form__cexp_t(&__pat___3->t2, &for_check_opt_0);
      FX_COPY_PTR(__pat___3->t3, &for_incrs_0);
      FX_COPY_PTR(__fold_result___2, &for_ccode_1);
      bool t_6;
      if (k_1 > 0) {
         t_6 = true;
      }
      else {
         t_6 = !add_incr_dstptr_1;
      }
      if (t_6) {
         FX_COPY_PTR(for_incrs_0, &for_incrs_1);
      }
      else {
         _fx_LN14C_form__cexp_t lstend_0 = 0;
         _fx_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t lst_5 = dst_data_1;
         for (; lst_5; lst_5 = lst_5->tl) {
            _fx_N14C_form__cexp_t dst_ptr_3 = 0;
            _fx_T2N14C_form__ctyp_tR10Ast__loc_t v_107 = {0};
            _fx_N14C_form__cexp_t res_1 = 0;
            _fx_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t* __pat___4 = &lst_5->hd;
            FX_COPY_PTR(__pat___4->t3, &dst_ptr_3);
            _fx_make_T2N14C_form__ctyp_tR10Ast__loc_t(_fx_g20C_gen_code__CTypVoid, for_loc_0, &v_107);
            FX_CALL(
               _fx_M6C_formFM9CExpUnaryN14C_form__cexp_t3N16C_form__cunary_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t(
                  &_fx_g24C_gen_code__COpSuffixInc, dst_ptr_3, &v_107, &res_1), _fx_catch_16);
            _fx_LN14C_form__cexp_t node_0 = 0;
            FX_CALL(_fx_cons_LN14C_form__cexp_t(res_1, 0, false, &node_0), _fx_catch_16);
            FX_LIST_APPEND(v_101, lstend_0, node_0);

         _fx_catch_16: ;
            if (res_1) {
               _fx_free_N14C_form__cexp_t(&res_1);
            }
            _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_107);
            if (dst_ptr_3) {
               _fx_free_N14C_form__cexp_t(&dst_ptr_3);
            }
            FX_CHECK_EXN(_fx_catch_21);
         }
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN14C_form__cexp_t2LN14C_form__cexp_tLN14C_form__cexp_t(for_incrs_0, v_101, &for_incrs_1,
               0), _fx_catch_21);
      }
      bool insert_pragma_0;
      bool t_7;
      if (for_idx_0 == 0) {
         t_7 = is_parallel_map_0;
      }
      else {
         t_7 = false;
      }
      if (t_7) {
         insert_pragma_0 = k_1 + 1 == nfor_headers_0;
      }
      else {
         insert_pragma_0 = false;
      }
      if (!insert_pragma_0) {
         FX_COPY_PTR(for_ccode_1, &for_body_ccode_0);
      }
      else {
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(for_ccode_1,
               decl_nested_status_0, &for_body_ccode_0, 0), _fx_catch_21);
      }
      if (insert_pragma_0 == false) {
         if (t_opt_0.tag == 2) {
            if (post_ccode_0 != 0) {
               _fx_make_Ta2Nt6option1N14C_form__ctyp_t(&_fx_g18C_gen_code__None1_, &t_opt_0, &v_102); goto _fx_endmatch_2;
            }
         }
      }
      _fx_make_Ta2Nt6option1N14C_form__ctyp_t(&t_opt_0, &_fx_g18C_gen_code__None1_, &v_102);

   _fx_endmatch_2: ;
      FX_CHECK_EXN(_fx_catch_21);
      _fx_copy_Nt6option1N14C_form__ctyp_t(&v_102.t0, &t_opt_1);
      _fx_copy_Nt6option1N14C_form__ctyp_t(&v_102.t1, &init_t_opt_0);
      if (init_t_opt_0.tag == 2) {
         _fx_LN15C_form__cstmt_t __fold_result___5 = 0;
         _fx_LN14C_form__cexp_t lst_6 = for_inits_0;
         for (; lst_6; lst_6 = lst_6->tl) {
            _fx_LN15C_form__cstmt_t for_ccode_6 = 0;
            _fx_LN15C_form__cstmt_t v_108 = 0;
            _fx_N14C_form__cexp_t e_0 = lst_6->hd;
            FX_COPY_PTR(__fold_result___5, &for_ccode_6);
            if (FX_REC_VARIANT_TAG(e_0) == 3) {
               _fx_T4N17C_form__cbinary_tN14C_form__cexp_tN14C_form__cexp_tT2N14C_form__ctyp_tR10Ast__loc_t* vcase_0 =
                  &e_0->u.CExpBinary;
               if (vcase_0->t0.tag == 15) {
                  _fx_N14C_form__cexp_t v_109 = vcase_0->t1;
                  if (FX_REC_VARIANT_TAG(v_109) == 1) {
                     _fx_N15C_form__cstmt_t v_110 = 0;
                     _fx_T2R9Ast__id_tT2N14C_form__ctyp_tR10Ast__loc_t* vcase_1 = &v_109->u.CExpIdent;
                     FX_CALL(
                        _fx_M6C_formFM7CDefValN15C_form__cstmt_t4N14C_form__ctyp_tR9Ast__id_tNt6option1N14C_form__cexp_tR10Ast__loc_t(
                           init_t_opt_0.u.Some, &vcase_1->t0, &_fx_g18C_gen_code__None2_, &vcase_1->t1.t1, &v_110),
                        _fx_catch_17);
                     FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_110, for_ccode_6, true, &v_108), _fx_catch_17);

                  _fx_catch_17: ;
                     if (v_110) {
                        _fx_free_N15C_form__cstmt_t(&v_110);
                     }
                     goto _fx_endmatch_3;
                  }
               }
            }
            fx_exn_t v_111 = {0};
            _fx_R10Ast__loc_t v_112;
            FX_CALL(_fx_M6C_formFM12get_cexp_locR10Ast__loc_t1N14C_form__cexp_t(e_0, &v_112, 0), _fx_catch_18);
            fx_str_t slit_19 = FX_MAKE_STR("invalid expression in the for-loop initialization part (should be i=<exp0>)");
            FX_CALL(_fx_M3AstFM11compile_errE2RM5loc_tS(&v_112, &slit_19, &v_111, 0), _fx_catch_18);
            FX_THROW(&v_111, false, _fx_catch_18);

         _fx_catch_18: ;
            fx_free_exn(&v_111);

         _fx_endmatch_3: ;
            FX_CHECK_EXN(_fx_catch_19);
            _fx_free_LN15C_form__cstmt_t(&__fold_result___5);
            FX_COPY_PTR(v_108, &__fold_result___5);

         _fx_catch_19: ;
            if (v_108) {
               _fx_free_LN15C_form__cstmt_t(&v_108);
            }
            if (for_ccode_6) {
               _fx_free_LN15C_form__cstmt_t(&for_ccode_6);
            }
            FX_CHECK_EXN(_fx_catch_20);
         }
         FX_COPY_PTR(__fold_result___5, &for_ccode_2);

      _fx_catch_20: ;
         if (__fold_result___5) {
            _fx_free_LN15C_form__cstmt_t(&__fold_result___5);
         }
      }
      FX_CHECK_EXN(_fx_catch_21);
      FX_CALL(
         _fx_M6C_formFM11rccode2stmtN15C_form__cstmt_t2LN15C_form__cstmt_tR10Ast__loc_t(for_body_ccode_0, kloc_0, &v_103, 0),
         _fx_catch_21);
      FX_CALL(
         _fx_M6C_formFM8CStmtForN15C_form__cstmt_t6Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tN15C_form__cstmt_tR10Ast__loc_t(
            &t_opt_1, for_inits_0, &for_check_opt_0, for_incrs_1, v_103, kloc_0, &v_104), _fx_catch_21);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_104, for_ccode_2, true, &for_ccode_3), _fx_catch_21);
      if (!insert_pragma_0) {
         FX_COPY_PTR(for_ccode_3, &for_ccode_4);
      }
      else {
         fx_str_t slit_20 = FX_MAKE_STR("omp parallel for");
         FX_CALL(_fx_M6C_formFM12CMacroPragmaN15C_form__cstmt_t2SR10Ast__loc_t(&slit_20, kloc_0, &v_105), _fx_catch_21);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_105, 0, true, &v_106), _fx_catch_21);
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(for_ccode_3, v_106,
               &for_ccode_4, 0), _fx_catch_21);
      }
      bool t_8;
      if (k_1 > 0) {
         t_8 = true;
      }
      else {
         t_8 = pre_body_ccode_1 == 0;
      }
      if (t_8) {
         FX_COPY_PTR(for_ccode_4, &for_ccode_5);
      }
      else {
         FX_CALL(
            _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(for_ccode_4, pre_body_ccode_1,
               &for_ccode_5, 0), _fx_catch_21);
      }
      _fx_free_LN15C_form__cstmt_t(&__fold_result___2);
      FX_COPY_PTR(for_ccode_5, &__fold_result___2);

   _fx_catch_21: ;
      if (for_ccode_5) {
         _fx_free_LN15C_form__cstmt_t(&for_ccode_5);
      }
      if (v_106) {
         _fx_free_LN15C_form__cstmt_t(&v_106);
      }
      if (v_105) {
         _fx_free_N15C_form__cstmt_t(&v_105);
      }
      if (for_ccode_4) {
         _fx_free_LN15C_form__cstmt_t(&for_ccode_4);
      }
      if (for_ccode_3) {
         _fx_free_LN15C_form__cstmt_t(&for_ccode_3);
      }
      if (v_104) {
         _fx_free_N15C_form__cstmt_t(&v_104);
      }
      if (v_103) {
         _fx_free_N15C_form__cstmt_t(&v_103);
      }
      if (for_ccode_2) {
         _fx_free_LN15C_form__cstmt_t(&for_ccode_2);
      }
      _fx_free_Nt6option1N14C_form__ctyp_t(&init_t_opt_0);
      _fx_free_Nt6option1N14C_form__ctyp_t(&t_opt_1);
      _fx_free_Ta2Nt6option1N14C_form__ctyp_t(&v_102);
      if (for_body_ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&for_body_ccode_0);
      }
      if (v_101) {
         _fx_free_LN14C_form__cexp_t(&v_101);
      }
      if (for_incrs_1) {
         _fx_free_LN14C_form__cexp_t(&for_incrs_1);
      }
      if (for_ccode_1) {
         _fx_free_LN15C_form__cstmt_t(&for_ccode_1);
      }
      if (for_incrs_0) {
         _fx_free_LN14C_form__cexp_t(&for_incrs_0);
      }
      _fx_free_Nt6option1N14C_form__cexp_t(&for_check_opt_0);
      if (for_inits_0) {
         _fx_free_LN14C_form__cexp_t(&for_inits_0);
      }
      _fx_free_Nt6option1N14C_form__ctyp_t(&t_opt_0);
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___2, &for_ccode_0);
   bool res_2;
   FX_CALL(_fx_M3AstFM6__eq__B2RM4id_tRM4id_t(&br_label_0, &_fx_g9Ast__noid, &res_2, 0), _fx_cleanup);
   if (res_2) {
      FX_COPY_PTR(post_ccode_0, &post_ccode_1);
   }
   else {
      FX_CALL(_fx_M6C_formFM10CStmtLabelN15C_form__cstmt_t2R9Ast__id_tR10Ast__loc_t(&br_label_0, end_for_loc_0, &v_21),
         _fx_cleanup);
      FX_CALL(_fx_cons_LN15C_form__cstmt_t(v_21, post_ccode_0, true, &post_ccode_1), _fx_cleanup);
   }
   FX_CALL(
      _fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(for_ccode_0, init_ccode_1, &v_22,
         0), _fx_cleanup);
   FX_CALL(_fx_M10C_gen_codeFM7__add__LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(post_ccode_1, v_22, &v_23, 0),
      _fx_cleanup);
   _fx_make_Ta2LN15C_form__cstmt_t(pre_map_ccode_2, v_23, fx_result);

_fx_cleanup: ;
   FX_FREE_FP(&kexp2cexp_0);
   FX_FREE_FP(&process_for_0);
   _fx_free_T4N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(
      &v_0);
   if (init_kexp_0) {
      _fx_free_N14K_form__kexp_t(&init_kexp_0);
   }
   if (idoml_0) {
      _fx_free_LT2R9Ast__id_tN13K_form__dom_t(&idoml_0);
   }
   FX_FREE_LIST_SIMPLE(&at_ids_0);
   if (nested_e_idoml_0) {
      _fx_free_LT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_t(&nested_e_idoml_0);
   }
   if (v_1) {
      _fx_free_rNt6option1N14C_form__cexp_t(&v_1);
   }
   _fx_free_T2N14C_form__cexp_tLN15C_form__cstmt_t(&v_2);
   if (init_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&init_ccode_0);
   }
   if (lbl_0) {
      _fx_free_N14C_form__cexp_t(&lbl_0);
   }
   _fx_free_T8LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN14C_form__cexp_tLN15C_form__cstmt_tLN15C_form__cstmt_tLT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_tLN15C_form__cstmt_t(
      &v_3);
   if (for_headers_0) {
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&for_headers_0);
   }
   if (list_exps_0) {
      _fx_free_LN14C_form__cexp_t(&list_exps_0);
   }
   if (i_exps_0) {
      _fx_free_LN14C_form__cexp_t(&i_exps_0);
   }
   if (n_exps_0) {
      _fx_free_LN14C_form__cexp_t(&n_exps_0);
   }
   if (pre_map_ccode_delta_0) {
      _fx_free_LN15C_form__cstmt_t(&pre_map_ccode_delta_0);
   }
   if (pre_body_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_0);
   }
   if (body_elems_0) {
      _fx_free_LT3R9Ast__id_tN14C_form__cexp_tR16Ast__val_flags_t(&body_elems_0);
   }
   if (post_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&post_ccode_0);
   }
   _fx_free_T3iLN14C_form__cexp_tLN15C_form__cstmt_t(&v_4);
   if (n_exps_1) {
      _fx_free_LN14C_form__cexp_t(&n_exps_1);
   }
   if (lst_len_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&lst_len_ccode_0);
   }
   if (n_exps_2) {
      _fx_free_LN14C_form__cexp_t(&n_exps_2);
   }
   if (i_exps_1) {
      _fx_free_LN14C_form__cexp_t(&i_exps_1);
   }
   _fx_free_T5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&v_5);
   if (dst_exp0_0) {
      _fx_free_N14C_form__cexp_t(&dst_exp0_0);
   }
   if (alloc_array_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&alloc_array_ccode_0);
   }
   _fx_free_T2iLN14C_form__cexp_t(&__fold_result___0);
   _fx_free_T2iLN14C_form__cexp_t(&v_6);
   if (cmp_size_list_0) {
      _fx_free_LN14C_form__cexp_t(&cmp_size_list_0);
   }
   if (lbl_1) {
      _fx_free_N14C_form__cexp_t(&lbl_1);
   }
   if (__fold_result___1) {
      _fx_free_LN15C_form__cstmt_t(&__fold_result___1);
   }
   if (then_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&then_ccode_0);
   }
   if (cc_exp_0) {
      _fx_free_N14C_form__cexp_t(&cc_exp_0);
   }
   _fx_free_T2N14C_form__ctyp_tR10Ast__loc_t(&v_7);
   if (cc_exp_1) {
      _fx_free_N14C_form__cexp_t(&cc_exp_1);
   }
   if (else_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&else_ccode_0);
   }
   if (v_8) {
      _fx_free_N15C_form__cstmt_t(&v_8);
   }
   if (v_9) {
      _fx_free_N15C_form__cstmt_t(&v_9);
   }
   if (check_or_create_0) {
      _fx_free_N15C_form__cstmt_t(&check_or_create_0);
   }
   _fx_free_Ta2LN15C_form__cstmt_t(&v_10);
   if (v_11) {
      _fx_free_LN15C_form__cstmt_t(&v_11);
   }
   if (v_12) {
      _fx_free_LN15C_form__cstmt_t(&v_12);
   }
   if (v_13) {
      _fx_free_LN15C_form__cstmt_t(&v_13);
   }
   if (v_14) {
      _fx_free_LN15C_form__cstmt_t(&v_14);
   }
   if (v_15) {
      _fx_free_LN15C_form__cstmt_t(&v_15);
   }
   if (v_16) {
      _fx_free_LN15C_form__cstmt_t(&v_16);
   }
   if (pre_map_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&pre_map_ccode_1);
   }
   if (init_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&init_ccode_1);
   }
   if (body_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&body_ccode_0);
   }
   _fx_free_T4BLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tLN15C_form__cstmt_tTa2LN15C_form__cstmt_t(
      &v_17);
   if (dst_data_1) {
      _fx_free_LT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_t(&dst_data_1);
   }
   if (pre_body_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&pre_body_ccode_1);
   }
   if (pre_map_ccode_2) {
      _fx_free_LN15C_form__cstmt_t(&pre_map_ccode_2);
   }
   if (body_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&body_ccode_1);
   }
   _fx_free_T2R9Ast__id_tN15C_form__cstmt_t(&v_18);
   if (body_stmt_0) {
      _fx_free_N15C_form__cstmt_t(&body_stmt_0);
   }
   if (v_19) {
      _fx_free_LN15C_form__cstmt_t(&v_19);
   }
   if (__fold_result___2) {
      _fx_free_LN15C_form__cstmt_t(&__fold_result___2);
   }
   if (v_20) {
      _fx_free_LT4Nt6option1N14C_form__ctyp_tLN14C_form__cexp_tNt6option1N14C_form__cexp_tLN14C_form__cexp_t(&v_20);
   }
   if (for_ccode_0) {
      _fx_free_LN15C_form__cstmt_t(&for_ccode_0);
   }
   if (post_ccode_1) {
      _fx_free_LN15C_form__cstmt_t(&post_ccode_1);
   }
   if (v_21) {
      _fx_free_N15C_form__cstmt_t(&v_21);
   }
   if (v_22) {
      _fx_free_LN15C_form__cstmt_t(&v_22);
   }
   if (v_23) {
      _fx_free_LN15C_form__cstmt_t(&v_23);
   }
   return fx_status;
}

FX_EXTERN_C int
   _fx_M10C_gen_codeFM7make_fpFPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB5rLrRM11block_ctx_trNt10Hashset__t1R9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_ti(
   struct _fx_rLrR23C_gen_code__block_ctx_t_data_t* arg0,
   struct _fx_rNt10Hashset__t1R9Ast__id_t_data_t* arg1,
   struct _fx_rLN15C_form__cstmt_t_data_t* arg2,
   struct _fx_rNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_t_data_t* arg3,
   int_ arg4,
   struct _fx_FPTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrR23C_gen_code__block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB*
      fx_result)
{
   FX_MAKE_FP_IMPL_START(
      _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB_cldata_t,
      _fx_free_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB,
      _fx_M10C_gen_codeFM8form_mapTa2LN15C_form__cstmt_t34LN15C_form__cstmt_tiLT3N14K_form__kexp_tLT2R9Ast__id_tN13K_form__dom_tLR9Ast__id_tLN14C_form__cexp_tLN14C_form__cexp_trLrRM11block_ctx_tLN15C_form__cstmt_trNt10Hashset__t1R9Ast__id_tLT5N14C_form__ctyp_tN14C_form__ctyp_tN14C_form__cexp_tN14C_form__cexp_tN14C_form__cexp_tR10Ast__loc_tN15Ast__for_make_tLSR10Ast__loc_trrNt6option1N14C_form__cexp_trLN15C_form__cstmt_tR9Ast__id_trLN15C_form__cstmt_trNt10Hashmap__t2R9Ast__id_tN14C_form__cexp_tBR10Ast__loc_tiN14C_form__cexp_tLN12Ast__scope_trLN15C_form__cstmt_tiBN14C_form__cexp_tiN14C_form__cexp_tBrirLN15C_form__cstmt_tNt10Hashset__t1R9Ast__id_tB);
   FX_COPY_PTR(arg0, &fcv->t0);
   FX_COPY_PTR(arg1, &fcv->t1);
   FX_COPY_PTR(arg2, &fcv->t2);
   FX_COPY_PTR(arg3, &fcv->t3);
   fcv->t4 = arg4;
   return 0;
}

FX_EXTERN_C int _fx_M10C_gen_codeFM13gen_ccode_allLR17C_form__cmodule_t1LR17K_form__kmodule_t(
   struct _fx_LR17K_form__kmodule_t_data_t* kmods_0,
   struct _fx_LR17C_form__cmodule_t_data_t** fx_result,
   void* fx_fv)
{
   _fx_Ta3LN15C_form__cstmt_t v_0 = {0};
   _fx_LN15C_form__cstmt_t all_ctypes_fwd_decl_0 = 0;
   _fx_LN15C_form__cstmt_t all_ctypes_decl_0 = 0;
   _fx_LN15C_form__cstmt_t all_ctypes_fun_decl_0 = 0;
   _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t __fold_result___0 =
      {0};
   _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t v_1 = {0};
   _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t kmods_plus_0 = 0;
   _fx_LR17C_form__cmodule_t __fold_result___1 = 0;
   _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t __fold_result___2 = 0;
   _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t v_2 = 0;
   _fx_LR17C_form__cmodule_t cmods_0 = 0;
   _fx_LR17C_form__cmodule_t __fold_result___3 = 0;
   int fx_status = 0;
   FX_CALL(_fx_M11C_gen_typesFM16convert_all_typsTa3LN15C_form__cstmt_t1LR17K_form__kmodule_t(kmods_0, &v_0, 0), _fx_cleanup);
   FX_COPY_PTR(v_0.t0, &all_ctypes_fwd_decl_0);
   FX_COPY_PTR(v_0.t1, &all_ctypes_decl_0);
   FX_COPY_PTR(v_0.t2, &all_ctypes_fun_decl_0);
   fx_str_t slit_0 = FX_MAKE_STR("\ttypes definitions have been translated to C");
   FX_CALL(_fx_M3AstFM10pr_verbosev1S(&slit_0, 0), _fx_cleanup);
   _fx_make_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(0, 0,
      &__fold_result___0);
   _fx_LR17K_form__kmodule_t lst_0 = kmods_0;
   for (; lst_0; lst_0 = lst_0->tl) {
      _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t v_3 = {0};
      _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t kmods_plus_1 = 0;
      _fx_LN15C_form__cstmt_t all_exn_data_decls_0 = 0;
      _fx_LN14K_form__kexp_t v_4 = 0;
      _fx_Ta3LN15C_form__cstmt_t v_5 = {0};
      _fx_LN15C_form__cstmt_t c_fdecls_0 = 0;
      _fx_LN15C_form__cstmt_t mod_init_calls_0 = 0;
      _fx_LN15C_form__cstmt_t mod_exn_data_decls_0 = 0;
      _fx_LN15C_form__cstmt_t __fold_result___4 = 0;
      _fx_LN15C_form__cstmt_t v_6 = 0;
      _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t v_7 = {0};
      _fx_LN15C_form__cstmt_t __fold_result___5 = 0;
      _fx_LN15C_form__cstmt_t v_8 = 0;
      _fx_LN15C_form__cstmt_t v_9 = 0;
      _fx_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t v_10 = {0};
      _fx_R17K_form__kmodule_t* km_0 = &lst_0->hd;
      _fx_copy_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         &__fold_result___0, &v_3);
      FX_COPY_PTR(v_3.t0, &kmods_plus_1);
      FX_COPY_PTR(v_3.t1, &all_exn_data_decls_0);
      FX_COPY_PTR(km_0->km_top, &v_4);
      FX_CALL(_fx_M12C_gen_fdeclsFM18convert_all_fdeclsTa3LN15C_form__cstmt_t2iLN14K_form__kexp_t(km_0->km_idx, v_4, &v_5, 0),
         _fx_catch_4);
      FX_COPY_PTR(v_5.t0, &c_fdecls_0);
      FX_COPY_PTR(v_5.t1, &mod_init_calls_0);
      FX_COPY_PTR(v_5.t2, &mod_exn_data_decls_0);
      _fx_LN15C_form__cstmt_t lst_1 = all_exn_data_decls_0;
      for (; lst_1; lst_1 = lst_1->tl) {
         _fx_LN15C_form__cstmt_t r_0 = 0;
         _fx_N15C_form__cstmt_t a_0 = lst_1->hd;
         FX_COPY_PTR(__fold_result___4, &r_0);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(a_0, r_0, false, &r_0), _fx_catch_0);
         _fx_free_LN15C_form__cstmt_t(&__fold_result___4);
         FX_COPY_PTR(r_0, &__fold_result___4);

      _fx_catch_0: ;
         if (r_0) {
            _fx_free_LN15C_form__cstmt_t(&r_0);
         }
         FX_CHECK_EXN(_fx_catch_4);
      }
      FX_COPY_PTR(__fold_result___4, &v_6);
      _fx_make_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(km_0, c_fdecls_0,
         mod_init_calls_0, v_6, &v_7);
      FX_CALL(
         _fx_cons_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_7, kmods_plus_1, false,
            &kmods_plus_1), _fx_catch_4);
      _fx_LN15C_form__cstmt_t lst_2 = mod_exn_data_decls_0;
      for (; lst_2; lst_2 = lst_2->tl) {
         _fx_LN15C_form__cstmt_t r_1 = 0;
         _fx_N15C_form__cstmt_t a_1 = lst_2->hd;
         FX_COPY_PTR(__fold_result___5, &r_1);
         FX_CALL(_fx_cons_LN15C_form__cstmt_t(a_1, r_1, false, &r_1), _fx_catch_1);
         _fx_free_LN15C_form__cstmt_t(&__fold_result___5);
         FX_COPY_PTR(r_1, &__fold_result___5);

      _fx_catch_1: ;
         if (r_1) {
            _fx_free_LN15C_form__cstmt_t(&r_1);
         }
         FX_CHECK_EXN(_fx_catch_4);
      }
      FX_COPY_PTR(__fold_result___5, &v_8);
      if (v_8 == 0) {
         FX_COPY_PTR(all_exn_data_decls_0, &v_9);
      }
      else if (all_exn_data_decls_0 == 0) {
         FX_COPY_PTR(v_8, &v_9);
      }
      else {
         _fx_LN15C_form__cstmt_t v_11 = 0;
         _fx_LN15C_form__cstmt_t lstend_0 = 0;
         _fx_LN15C_form__cstmt_t lst_3 = v_8;
         for (; lst_3; lst_3 = lst_3->tl) {
            _fx_N15C_form__cstmt_t x_0 = lst_3->hd;
            _fx_LN15C_form__cstmt_t node_0 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_0, 0, false, &node_0), _fx_catch_2);
            FX_LIST_APPEND(v_11, lstend_0, node_0);

         _fx_catch_2: ;
            FX_CHECK_EXN(_fx_catch_3);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_11, all_exn_data_decls_0, &v_9,
            0);

      _fx_catch_3: ;
         if (v_11) {
            _fx_free_LN15C_form__cstmt_t(&v_11);
         }
      }
      FX_CHECK_EXN(_fx_catch_4);
      _fx_make_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         kmods_plus_1, v_9, &v_10);
      _fx_free_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
         &__fold_result___0);
      _fx_copy_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_10,
         &__fold_result___0);

   _fx_catch_4: ;
      _fx_free_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_10);
      if (v_9) {
         _fx_free_LN15C_form__cstmt_t(&v_9);
      }
      if (v_8) {
         _fx_free_LN15C_form__cstmt_t(&v_8);
      }
      if (__fold_result___5) {
         _fx_free_LN15C_form__cstmt_t(&__fold_result___5);
      }
      _fx_free_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_7);
      if (v_6) {
         _fx_free_LN15C_form__cstmt_t(&v_6);
      }
      if (__fold_result___4) {
         _fx_free_LN15C_form__cstmt_t(&__fold_result___4);
      }
      if (mod_exn_data_decls_0) {
         _fx_free_LN15C_form__cstmt_t(&mod_exn_data_decls_0);
      }
      if (mod_init_calls_0) {
         _fx_free_LN15C_form__cstmt_t(&mod_init_calls_0);
      }
      if (c_fdecls_0) {
         _fx_free_LN15C_form__cstmt_t(&c_fdecls_0);
      }
      _fx_free_Ta3LN15C_form__cstmt_t(&v_5);
      if (v_4) {
         _fx_free_LN14K_form__kexp_t(&v_4);
      }
      if (all_exn_data_decls_0) {
         _fx_free_LN15C_form__cstmt_t(&all_exn_data_decls_0);
      }
      if (kmods_plus_1) {
         _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&kmods_plus_1);
      }
      _fx_free_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_3);
      FX_CHECK_EXN(_fx_cleanup);
   }
   _fx_copy_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
      &__fold_result___0, &v_1);
   FX_COPY_PTR(v_1.t0, &kmods_plus_0);
   fx_str_t slit_1 = FX_MAKE_STR("\tfunction declarations and exceptions have been translated to C");
   FX_CALL(_fx_M3AstFM10pr_verbosev1S(&slit_1, 0), _fx_cleanup);
   _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t lst_4 = kmods_plus_0;
   for (; lst_4; lst_4 = lst_4->tl) {
      _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t r_2 = 0;
      _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* a_2 = &lst_4->hd;
      FX_COPY_PTR(__fold_result___2, &r_2);
      FX_CALL(_fx_cons_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(a_2, r_2, false, &r_2),
         _fx_catch_5);
      _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&__fold_result___2);
      FX_COPY_PTR(r_2, &__fold_result___2);

   _fx_catch_5: ;
      if (r_2) {
         _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&r_2);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___2, &v_2);
   _fx_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t lst_5 = v_2;
   for (; lst_5; lst_5 = lst_5->tl) {
      _fx_R17K_form__kmodule_t km_1 = {0};
      _fx_LN15C_form__cstmt_t c_fdecls_1 = 0;
      _fx_LN15C_form__cstmt_t mod_init_calls_1 = 0;
      _fx_LN15C_form__cstmt_t exn_data_decls_0 = 0;
      _fx_LR17C_form__cmodule_t cmods_1 = 0;
      _fx_R14Ast__pragmas_t km_pragmas_0 = {0};
      fx_str_t km_cname_0 = {0};
      _fx_Ta2LN15C_form__cstmt_t v_12 = {0};
      _fx_LN15C_form__cstmt_t prologue_0 = 0;
      _fx_LN15C_form__cstmt_t ccode_0 = 0;
      _fx_LN15C_form__cstmt_t v_13 = 0;
      _fx_LN15C_form__cstmt_t ctypes_0 = 0;
      fx_str_t v_14 = {0};
      _fx_LN15C_form__cstmt_t v_15 = 0;
      _fx_LN15C_form__cstmt_t v_16 = 0;
      _fx_R17C_form__cmodule_t v_17 = {0};
      _fx_LR17C_form__cmodule_t v_18 = 0;
      _fx_T4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t* __pat___0 = &lst_5->hd;
      _fx_copy_R17K_form__kmodule_t(&__pat___0->t0, &km_1);
      FX_COPY_PTR(__pat___0->t1, &c_fdecls_1);
      FX_COPY_PTR(__pat___0->t2, &mod_init_calls_1);
      FX_COPY_PTR(__pat___0->t3, &exn_data_decls_0);
      FX_COPY_PTR(__fold_result___1, &cmods_1);
      _fx_copy_R14Ast__pragmas_t(&km_1.km_pragmas, &km_pragmas_0);
      bool km_skip_0 = km_1.km_skip;
      bool km_main_0 = km_1.km_main;
      fx_copy_str(&km_1.km_cname, &km_cname_0);
      _fx_R9Ast__id_t km_name_0 = km_1.km_name;
      FX_CALL(
         _fx_M10C_gen_codeFM9gen_ccodeTa2LN15C_form__cstmt_t4LR17C_form__cmodule_tR17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            cmods_1, &km_1, c_fdecls_1, mod_init_calls_1, &v_12, 0), _fx_catch_12);
      FX_COPY_PTR(v_12.t0, &prologue_0);
      FX_COPY_PTR(v_12.t1, &ccode_0);
      _fx_R9Ast__id_t v_19 = km_1.km_name;
      if (all_ctypes_decl_0 == 0) {
         FX_COPY_PTR(exn_data_decls_0, &v_13);
      }
      else if (exn_data_decls_0 == 0) {
         FX_COPY_PTR(all_ctypes_decl_0, &v_13);
      }
      else {
         _fx_LN15C_form__cstmt_t v_20 = 0;
         _fx_LN15C_form__cstmt_t lstend_1 = 0;
         _fx_LN15C_form__cstmt_t lst_6 = all_ctypes_decl_0;
         for (; lst_6; lst_6 = lst_6->tl) {
            _fx_N15C_form__cstmt_t x_1 = lst_6->hd;
            _fx_LN15C_form__cstmt_t node_1 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_1, 0, false, &node_1), _fx_catch_6);
            FX_LIST_APPEND(v_20, lstend_1, node_1);

         _fx_catch_6: ;
            FX_CHECK_EXN(_fx_catch_7);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_20, exn_data_decls_0, &v_13, 0);

      _fx_catch_7: ;
         if (v_20) {
            _fx_free_LN15C_form__cstmt_t(&v_20);
         }
      }
      FX_CHECK_EXN(_fx_catch_12);
      FX_CALL(
         _fx_M11C_gen_typesFM18elim_unused_ctypesLN15C_form__cstmt_t5R9Ast__id_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
            &v_19, all_ctypes_fwd_decl_0, v_13, all_ctypes_fun_decl_0, ccode_0, &ctypes_0, 0), _fx_catch_12);
      FX_CALL(_fx_M8K_mangleFM12mangle_mnameS1S(&km_cname_0, &v_14, 0), _fx_catch_12);
      if (ctypes_0 == 0) {
         FX_COPY_PTR(ccode_0, &v_15);
      }
      else if (ccode_0 == 0) {
         FX_COPY_PTR(ctypes_0, &v_15);
      }
      else {
         _fx_LN15C_form__cstmt_t v_21 = 0;
         _fx_LN15C_form__cstmt_t lstend_2 = 0;
         _fx_LN15C_form__cstmt_t lst_7 = ctypes_0;
         for (; lst_7; lst_7 = lst_7->tl) {
            _fx_N15C_form__cstmt_t x_2 = lst_7->hd;
            _fx_LN15C_form__cstmt_t node_2 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_2, 0, false, &node_2), _fx_catch_8);
            FX_LIST_APPEND(v_21, lstend_2, node_2);

         _fx_catch_8: ;
            FX_CHECK_EXN(_fx_catch_9);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_21, ccode_0, &v_15, 0);

      _fx_catch_9: ;
         if (v_21) {
            _fx_free_LN15C_form__cstmt_t(&v_21);
         }
      }
      FX_CHECK_EXN(_fx_catch_12);
      if (prologue_0 == 0) {
         FX_COPY_PTR(v_15, &v_16);
      }
      else if (v_15 == 0) {
         FX_COPY_PTR(prologue_0, &v_16);
      }
      else {
         _fx_LN15C_form__cstmt_t v_22 = 0;
         _fx_LN15C_form__cstmt_t lstend_3 = 0;
         _fx_LN15C_form__cstmt_t lst_8 = prologue_0;
         for (; lst_8; lst_8 = lst_8->tl) {
            _fx_N15C_form__cstmt_t x_3 = lst_8->hd;
            _fx_LN15C_form__cstmt_t node_3 = 0;
            FX_CALL(_fx_cons_LN15C_form__cstmt_t(x_3, 0, false, &node_3), _fx_catch_10);
            FX_LIST_APPEND(v_22, lstend_3, node_3);

         _fx_catch_10: ;
            FX_CHECK_EXN(_fx_catch_11);
         }
         _fx_M10C_gen_codeFM5link2LN15C_form__cstmt_t2LN15C_form__cstmt_tLN15C_form__cstmt_t(v_22, v_15, &v_16, 0);

      _fx_catch_11: ;
         if (v_22) {
            _fx_free_LN15C_form__cstmt_t(&v_22);
         }
      }
      FX_CHECK_EXN(_fx_catch_12);
      _fx_make_R17C_form__cmodule_t(&km_name_0, &v_14, v_16, km_main_0, true, km_skip_0, &km_pragmas_0, &v_17);
      FX_CALL(_fx_cons_LR17C_form__cmodule_t(&v_17, cmods_1, true, &v_18), _fx_catch_12);
      _fx_free_LR17C_form__cmodule_t(&__fold_result___1);
      FX_COPY_PTR(v_18, &__fold_result___1);

   _fx_catch_12: ;
      if (v_18) {
         _fx_free_LR17C_form__cmodule_t(&v_18);
      }
      _fx_free_R17C_form__cmodule_t(&v_17);
      if (v_16) {
         _fx_free_LN15C_form__cstmt_t(&v_16);
      }
      if (v_15) {
         _fx_free_LN15C_form__cstmt_t(&v_15);
      }
      FX_FREE_STR(&v_14);
      if (ctypes_0) {
         _fx_free_LN15C_form__cstmt_t(&ctypes_0);
      }
      if (v_13) {
         _fx_free_LN15C_form__cstmt_t(&v_13);
      }
      if (ccode_0) {
         _fx_free_LN15C_form__cstmt_t(&ccode_0);
      }
      if (prologue_0) {
         _fx_free_LN15C_form__cstmt_t(&prologue_0);
      }
      _fx_free_Ta2LN15C_form__cstmt_t(&v_12);
      FX_FREE_STR(&km_cname_0);
      _fx_free_R14Ast__pragmas_t(&km_pragmas_0);
      if (cmods_1) {
         _fx_free_LR17C_form__cmodule_t(&cmods_1);
      }
      if (exn_data_decls_0) {
         _fx_free_LN15C_form__cstmt_t(&exn_data_decls_0);
      }
      if (mod_init_calls_1) {
         _fx_free_LN15C_form__cstmt_t(&mod_init_calls_1);
      }
      if (c_fdecls_1) {
         _fx_free_LN15C_form__cstmt_t(&c_fdecls_1);
      }
      _fx_free_R17K_form__kmodule_t(&km_1);
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___1, &cmods_0);
   fx_str_t slit_2 = FX_MAKE_STR("\tall modules have been translated");
   FX_CALL(_fx_M3AstFM10pr_verbosev1S(&slit_2, 0), _fx_cleanup);
   _fx_LR17C_form__cmodule_t lst_9 = cmods_0;
   for (; lst_9; lst_9 = lst_9->tl) {
      _fx_LR17C_form__cmodule_t r_3 = 0;
      _fx_R17C_form__cmodule_t* a_3 = &lst_9->hd;
      FX_COPY_PTR(__fold_result___3, &r_3);
      FX_CALL(_fx_cons_LR17C_form__cmodule_t(a_3, r_3, false, &r_3), _fx_catch_13);
      _fx_free_LR17C_form__cmodule_t(&__fold_result___3);
      FX_COPY_PTR(r_3, &__fold_result___3);

   _fx_catch_13: ;
      if (r_3) {
         _fx_free_LR17C_form__cmodule_t(&r_3);
      }
      FX_CHECK_EXN(_fx_cleanup);
   }
   FX_COPY_PTR(__fold_result___3, fx_result);

_fx_cleanup: ;
   _fx_free_Ta3LN15C_form__cstmt_t(&v_0);
   if (all_ctypes_fwd_decl_0) {
      _fx_free_LN15C_form__cstmt_t(&all_ctypes_fwd_decl_0);
   }
   if (all_ctypes_decl_0) {
      _fx_free_LN15C_form__cstmt_t(&all_ctypes_decl_0);
   }
   if (all_ctypes_fun_decl_0) {
      _fx_free_LN15C_form__cstmt_t(&all_ctypes_fun_decl_0);
   }
   _fx_free_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(
      &__fold_result___0);
   _fx_free_T2LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_1);
   if (kmods_plus_0) {
      _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&kmods_plus_0);
   }
   if (__fold_result___1) {
      _fx_free_LR17C_form__cmodule_t(&__fold_result___1);
   }
   if (__fold_result___2) {
      _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&__fold_result___2);
   }
   if (v_2) {
      _fx_free_LT4R17K_form__kmodule_tLN15C_form__cstmt_tLN15C_form__cstmt_tLN15C_form__cstmt_t(&v_2);
   }
   if (cmods_0) {
      _fx_free_LR17C_form__cmodule_t(&cmods_0);
   }
   if (__fold_result___3) {
      _fx_free_LR17C_form__cmodule_t(&__fold_result___3);
   }
   return fx_status;
}

FX_EXTERN_C int fx_init_C_gen_code(void)
{
   int fx_status = 0;
   return fx_status;
}

FX_EXTERN_C void fx_deinit_C_gen_code(void)
{

}

